Mercurial > code > home > repos > video
changeset 35:814bda860dda
rename
author | drewp@bigasterisk.com |
---|---|
date | Mon, 02 Dec 2024 23:27:59 -0800 |
parents | 9edb3df3cdb3 |
children | ed16fdbb3996 |
files | deploy.yaml deploy_files.yaml skaffold.yaml |
diffstat | 3 files changed, 70 insertions(+), 70 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/deploy.yaml Mon Dec 02 23:27:59 2024 -0800 @@ -0,0 +1,69 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: video-files +spec: + replicas: 2 + selector: + matchLabels: + app: video-files + template: + metadata: + labels: + app: video-files + annotations: + prometheus.io/scrape: "true" + prometheus.io/port: "8004" + spec: + volumes: + - name: data + persistentVolumeClaim: + claimName: video-data + containers: + - name: files + image: reg:5000/video_image + # alternate: [ "webfsd", "-Fp", "9054", "-r", "/vids/" ] + command: + - pnpm + - exec + - node + - ./serve-files.js + ports: + - containerPort: 8003 + volumeMounts: + - { name: data, mountPath: /data } + + - name: api + image: reg:5000/video_image + command: + - pdm + - run + - python + - video.py + ports: + - containerPort: 8004 + volumeMounts: + - { name: data, mountPath: /data } + resources: + requests: + cpu: "2" + + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: "kubernetes.io/hostname" + operator: In + values: ["ditto"] +--- +apiVersion: v1 +kind: Service +metadata: + name: video-files +spec: + ports: + - { port: 8003, targetPort: 8003, name: files } + - { port: 8004, targetPort: 8004, name: api } + selector: + app: video-files
--- a/deploy_files.yaml Mon Aug 26 22:34:44 2024 -0700 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,69 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: video-files -spec: - replicas: 2 - selector: - matchLabels: - app: video-files - template: - metadata: - labels: - app: video-files - annotations: - prometheus.io/scrape: "true" - prometheus.io/port: "8004" - spec: - volumes: - - name: data - persistentVolumeClaim: - claimName: video-data - containers: - - name: files - image: reg:5000/video_image - # alternate: [ "webfsd", "-Fp", "9054", "-r", "/vids/" ] - command: - - pnpm - - exec - - node - - ./serve-files.js - ports: - - containerPort: 8003 - volumeMounts: - - { name: data, mountPath: /data } - - - name: api - image: reg:5000/video_image - command: - - pdm - - run - - python - - video.py - ports: - - containerPort: 8004 - volumeMounts: - - { name: data, mountPath: /data } - resources: - requests: - cpu: "2" - - affinity: - nodeAffinity: - requiredDuringSchedulingIgnoredDuringExecution: - nodeSelectorTerms: - - matchExpressions: - - key: "kubernetes.io/hostname" - operator: In - values: ["ditto"] ---- -apiVersion: v1 -kind: Service -metadata: - name: video-files -spec: - ports: - - { port: 8003, targetPort: 8003, name: files } - - { port: 8004, targetPort: 8004, name: api } - selector: - app: video-files