Skip to content

Commit

Permalink
commiting all locally made manifests
Browse files Browse the repository at this point in the history
  • Loading branch information
Hamada Gasmallah committed Jan 19, 2023
1 parent 2ae4e87 commit 94a3cd1
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 0 deletions.
43 changes: 43 additions & 0 deletions deployment/gitsync-pod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
apiVersion: v1
kind: Pod
metadata:
name: backend
spec:
containers:
- name: backend
image: node:16-alpine
command:
- sh
- -c
- |
cd /var/app
sleep 10
npm i
npm run start
env:
- name: APP_PORT
value: "8080"
ports:
- containerPort: 8080
volumeMounts:
- name: repo
mountPath: "/var/app"
- name: git-sync-sidecar
image: k8s.gcr.io/git-sync:v3.1.6
volumeMounts:
- name: repo
mountPath: /git
env:
- name: GIT_SYNC_ROOT
value: "/git"
- name: GIT_SYNC_REPO
value: "[email protected]:Hamada-Distributed/k8s-toyapp.git"
- name: GIT_SYNC_BRANCH
value: "release"
- name: GIT_SYNC_MAX_FAILURES
value: "3"
- name: GIT_SYNC_PERIOD
value: "600"
volumes:
- name: repo
emptyDir: {}
13 changes: 13 additions & 0 deletions deployment/pod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: v1
kind: Pod
metadata:
name: backend
spec:
containers:
- name: backend
image: ghcr.io/hamada-distributed/k8s-toyapp:backend
env:
- name: APP_PORT
value: "8080"
ports:
- containerPort: 8080

0 comments on commit 94a3cd1

Please sign in to comment.