-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: build and deploy from runner (TT-1536) (#24)
* Update action versions, get secrets from vault * Add k8s deployment file and pipeline job * Change sed separator * Revert "Change sed separator" This reverts commit 75accac. * Add deploy-to-prod job * Remove 'v' from image version * Use same k8s file template for stage and prod * Deploy to stage from main only
- Loading branch information
1 parent
0655456
commit c38b7da
Showing
2 changed files
with
197 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: meteor | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: meteor | ||
template: | ||
metadata: | ||
labels: | ||
app: meteor | ||
spec: | ||
volumes: | ||
- name: dimo-file-server-volume | ||
persistentVolumeClaim: | ||
claimName: <pvc_claim_name> | ||
containers: | ||
- name: app | ||
image: nationallibraryofnorway/meteor:<version> | ||
ports: | ||
- containerPort: 8000 | ||
env: | ||
- name: REGISTRY_HOST | ||
valueFrom: | ||
secretKeyRef: | ||
name: meteor-registry-secret | ||
key: host | ||
- name: REGISTRY_DATABASE | ||
valueFrom: | ||
secretKeyRef: | ||
name: meteor-registry-secret | ||
key: database | ||
- name: REGISTRY_USER | ||
valueFrom: | ||
secretKeyRef: | ||
name: meteor-registry-secret | ||
key: username | ||
- name: REGISTRY_PASSWORD | ||
valueFrom: | ||
secretKeyRef: | ||
name: meteor-registry-secret | ||
key: password | ||
- name: MOUNT_FOLDER | ||
value: "/dimo-file-server" | ||
- name: MAX_FILE_SIZE_MB | ||
value: "10000" | ||
- name: ENVIRONMENT | ||
value: "stage" | ||
- name: LANGUAGES | ||
value: "mul,eng,nob,nno" | ||
- name: USE_GIELLADETECT | ||
value: "True" | ||
- name: GIELLADETECT_LANGS | ||
value: "nno,nob,eng,sme,sma,smj" | ||
volumeMounts: | ||
- name: dimo-file-server-volume | ||
mountPath: /dimo-file-server | ||
imagePullPolicy: Always | ||
|
||
--- | ||
|
||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: meteor-service | ||
spec: | ||
ports: | ||
- port: 8000 | ||
name: http | ||
targetPort: 8000 | ||
selector: | ||
app: meteor | ||
type: ClusterIP | ||
|
||
--- | ||
|
||
apiVersion: networking.k8s.io/v1 | ||
kind: Ingress | ||
metadata: | ||
name: meteor-ingress | ||
spec: | ||
rules: | ||
- host: <host_url> | ||
http: | ||
paths: | ||
- path: /meteor | ||
pathType: Prefix | ||
backend: | ||
service: | ||
name: meteor-service | ||
port: | ||
number: 8000 |