-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdeploy.yaml
62 lines (60 loc) · 1.65 KB
/
deploy.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
apiVersion: v1
kind: Pod
metadata:
name: kaniko
spec:
initContainers:
- name: builder
image: mohamedrafraf/builder:pfa
volumeMounts:
- name: workdir
mountPath: "/workdir"
env:
- name: TECHNOLOGY
value: python
- name: Version
value: "3.7"
- name: REPO_URL
value: https://github.com/hmlndrr/feminist.git
- name: APP_NAME
value: feminist
- name: INSTALL_CMD
value: "pip install --no-cache-dir -r requirements.txt"
- name: RUN_CMD
value: "gunicorn --bind 0.0.0.0:80 main:app"
- name: STATIC
value: "false"
- name: PORT
value: "80"
- name: ENVARS
value: "APP=Feminist;AUTHOR=Nie"
- name: DEPENDENCIES
value: "requirements.txt"
- name: init-myservice
image: busybox:1.28
command: ['sh', '-c', "sleep 1"]
volumeMounts:
- name: workdir
mountPath: "/workdir"
containers:
- name: kaniko
image: gcr.io/kaniko-project/executor:latest
args:
- "--dockerfile=/workdir/feminist/Dockerfile"
- "--context=dir:///workdir/feminist"
- "--destination=us-central1-docker.pkg.dev/esoteric-might-387308/kli8nt/feminist:latest"
volumeMounts:
- name: kaniko-secret
mountPath: /secret
- name: workdir
mountPath: "/workdir"
env:
- name: GOOGLE_APPLICATION_CREDENTIALS
value: /secret/kaniko-secret.json
restartPolicy: Never
volumes:
- name: workdir
emptyDir: {}
- name: kaniko-secret
secret:
secretName: kaniko-secret