Skip to content

Commit

Permalink
deploy sample app with mssql connection on aro 4 cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
majguo committed Jun 18, 2020
1 parent 5ac8da9 commit f97f8f7
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
12 changes: 12 additions & 0 deletions 3-integration/connect-db/mssql/mssql-secret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
apiVersion: v1
kind: Secret
metadata:
name: mssql-secret
namespace: open-liberty-demo
type: Opaque
stringData:
db.server.name: ${DB_SERVER_NAME}
db.port.number: ${DB_PORT_NUMBER}
db.name: ${DB_NAME}
db.user: ${DB_USER}
db.password: ${DB_PASSWORD}
26 changes: 26 additions & 0 deletions 3-integration/connect-db/mssql/openlibertyapplication.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,29 @@ spec:
# Note: replace "${Your_DockerHub_Account}" with your Docker Hub account name
applicationImage: docker.io/${Your_DockerHub_Account}/javaee-cafe-connect-db-mssql:latest
expose: true
env:
- name: DB_SERVER_NAME
valueFrom:
secretKeyRef:
name: mssql-secret
key: db.server.name
- name: DB_PORT_NUMBER
valueFrom:
secretKeyRef:
name: mssql-secret
key: db.port.number
- name: DB_NAME
valueFrom:
secretKeyRef:
name: mssql-secret
key: db.name
- name: DB_USER
valueFrom:
secretKeyRef:
name: mssql-secret
key: db.user
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: mssql-secret
key: db.password

0 comments on commit f97f8f7

Please sign in to comment.