-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(builder): move deis-builder to use Deployments
RC for deis-builder is kept around so it can be taken out of rotation without needing manual intervention (see replicas 0 and changed labels)
- Loading branch information
Showing
2 changed files
with
96 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
#helm:generate helm template -o $HELM_GENERATE_DIR/manifests/deis-builder-deployment.yaml -d $HELM_GENERATE_DIR/tpl/generate_params.toml $HELM_GENERATE_DIR/tpl/deis-builder-deployment.yaml | ||
apiVersion: extensions/v1beta1 | ||
kind: Deployment | ||
metadata: | ||
name: deis-builder | ||
namespace: deis | ||
labels: | ||
heritage: deis | ||
spec: | ||
replicas: 1 | ||
strategy: | ||
rollingUpdate: | ||
maxSurge: 1 | ||
maxUnavailable: 0 | ||
type: RollingUpdate | ||
selector: | ||
matchLabels: | ||
app: deis-builder | ||
template: | ||
metadata: | ||
labels: | ||
app: deis-builder | ||
spec: | ||
serviceAccount: deis-builder | ||
containers: | ||
- name: deis-builder | ||
image: quay.io/{{.builder.org}}/builder:{{ env "BUILDER_GIT_TAG" | default .builder.dockerTag}} | ||
imagePullPolicy: {{.builder.pullPolicy}} | ||
ports: | ||
- containerPort: 2223 | ||
name: ssh | ||
- containerPort: 8092 | ||
name: healthsrv | ||
env: | ||
- name: "HEALTH_SERVER_PORT" | ||
value: "8092" | ||
- name: "EXTERNAL_PORT" | ||
value: "2223" | ||
- name: BUILDER_STORAGE | ||
value: "{{ or (env "STORAGE_TYPE") (.storage)}}" | ||
# Set GIT_LOCK_TIMEOUT to number of minutes you want to wait to git push again to the same repository | ||
- name: "GIT_LOCK_TIMEOUT" | ||
value: "10" | ||
- name: "SLUGBUILDER_IMAGE_NAME" | ||
value: "quay.io/{{.slugbuilder.org}}/slugbuilder:{{ env "SLUGBUILDER_GIT_TAG" | default .slugbuilder.dockerTag }}" | ||
- name: "DOCKERBUILDER_IMAGE_NAME" | ||
value: "quay.io/{{.dockerbuilder.org}}/dockerbuilder:{{ env "DOCKERBUILDER_GIT_TAG" | default .dockerbuilder.dockerTag}}" | ||
# This var needs to be passed so that the minio client (https://github.com/minio/mc) will work in Alpine linux | ||
- name: "DOCKERIMAGE" | ||
value: "1" | ||
- name: "DEIS_DEBUG" | ||
value: "{{ env "DEIS_DEBUG" | default "false" }}" | ||
- name: "POD_NAMESPACE" | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: metadata.namespace | ||
- name: DEIS_BUILDER_KEY | ||
valueFrom: | ||
secretKeyRef: | ||
name: builder-key-auth | ||
key: builder-key | ||
livenessProbe: | ||
httpGet: | ||
path: /healthz | ||
port: 8092 | ||
initialDelaySeconds: 30 | ||
timeoutSeconds: 1 | ||
readinessProbe: | ||
httpGet: | ||
path: /readiness | ||
port: 8092 | ||
initialDelaySeconds: 30 | ||
timeoutSeconds: 1 | ||
volumeMounts: | ||
- name: builder-key-auth | ||
mountPath: /var/run/secrets/api/auth | ||
readOnly: true | ||
- name: builder-ssh-private-keys | ||
mountPath: /var/run/secrets/deis/builder/ssh | ||
readOnly: true | ||
- name: objectstore-creds | ||
mountPath: /var/run/secrets/deis/objectstore/creds | ||
readOnly: true | ||
volumes: | ||
- name: builder-key-auth | ||
secret: | ||
secretName: builder-key-auth | ||
- name: builder-ssh-private-keys | ||
secret: | ||
secretName: builder-ssh-private-keys | ||
- name: objectstore-creds | ||
secret: | ||
secretName: objectstorage-keyfile |
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