Skip to content

Instantly share code, notes, and snippets.

@dts
Created October 4, 2016 16:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dts/cbb93aea7dbfec77ac70a8c24d436253 to your computer and use it in GitHub Desktop.
Save dts/cbb93aea7dbfec77ac70a8c24d436253 to your computer and use it in GitHub Desktop.
Gitlab Runner Kubernetes YAML for AWS
aws ec2 create-volume --size 1 --availability-zone us-west-2b --volume-type standard
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: gitlab-runner
namespace: gitlab
spec:
replicas: 1
template:
metadata:
name: gitlab-runner
labels:
app: gitlab-runner
namespace: gitlab
spec:
nodeSelector:
failure-domain.beta.kubernetes.io/zone: us-west-2b
volumes:
- name: gitlab-config
awsElasticBlockStore:
volumeID: <<VOLUME ID FROM EARLIER>>
fsType: ext4
- name: docker-socket
hostPath:
path: /var/run/docker.sock
containers:
- name: gitlab-runner
image: gitlab/gitlab-runner:latest
volumeMounts:
- name: docker-socket
mountPath: /var/run/docker.sock
readOnly: false
- name: gitlab-config
mountPath: /etc/gitlab-runner
readOnly: false
resources:
requests:
memory: "128Mi"
cpu: "10m"
limits:
memory: "256Mi"
cpu: "50m"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment