job.yaml 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. apiVersion: batch/v1
  2. kind: Job
  3. metadata:
  4. name: guix-deploy-vm1
  5. spec:
  6. backoffLimit: 0
  7. template:
  8. spec:
  9. hostNetwork: true
  10. hostPID: true
  11. nodeSelector:
  12. kubernetes.io/hostname: kube1
  13. restartPolicy: Never
  14. containers:
  15. - command:
  16. - nsenter
  17. - --target
  18. - "1"
  19. - --mount
  20. - --uts
  21. - --ipc
  22. - --net
  23. - --pid
  24. - --no-fork
  25. - sh
  26. - -l
  27. - -c
  28. - sudo --chdir=$WORKSPACE --user=oleg --login guix time-machine --disable-authentication --channels=dotfiles/channels-current-local-file.scm -- deploy --load-path=dotfiles/guixsd/modules dotfiles/guixsd/deploy-vm1.wugi.info.scm
  29. env:
  30. - name: WORKSPACE
  31. value: /home/oleg/.local/share/chezmoi
  32. image: docker-registry.wugi.info/library/alpine
  33. name: refresh
  34. resources:
  35. limits:
  36. cpu: 8000m
  37. memory: 4096Mi
  38. requests:
  39. cpu: 1000m
  40. memory: 512Mi
  41. securityContext:
  42. privileged: true