Skip to content

Commit

Permalink
Merge pull request #20 from tssma/add-kubernetes
Browse files Browse the repository at this point in the history
Added Kubernetes support
  • Loading branch information
tssma authored Nov 30, 2024
2 parents 4854127 + f90a088 commit d8fa00a
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 0 deletions.
43 changes: 43 additions & 0 deletions deploy/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
apiVersion: apps/v1
kind: Deployment
metadata:
creationTimestamp: null
labels:
app: accounts
name: accounts
spec:
replicas: 3
selector:
matchLabels:
app: accounts
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
app: accounts
spec:
containers:
- image: us.icr.io/sn-labs-mattkarl/accounts:1
name: accounts
resources: {}

env:
- name: DATABASE_HOST
value: postgresql
- name: DATABASE_NAME
valueFrom:
secretKeyRef:
name: postgresql
key: database-name
- name: DATABASE_PASSWORD
valueFrom:
secretKeyRef:
name: postgresql
key: database-password
- name: DATABASE_USER
valueFrom:
secretKeyRef:
name: postgresql
key: database-user
status: {}
17 changes: 17 additions & 0 deletions deploy/service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
apiVersion: v1
kind: Service
metadata:
creationTimestamp: null
labels:
app: accounts
name: accounts
spec:
ports:
- port: 8080
protocol: TCP
targetPort: 8080
selector:
app: accounts
type: ClusterIP
status:
loadBalancer: {}

0 comments on commit d8fa00a

Please sign in to comment.