snapshot of dev before I switched tasks

This commit is contained in:
Clint Shryock 2018-10-29 10:36:23 -05:00
parent 9e8d74de04
commit 5d0ffcabe0
No known key found for this signature in database
GPG key ID: B7C8F9C70EC5CD29
2 changed files with 29 additions and 17 deletions

View file

@ -27,6 +27,11 @@ spec:
release: {{ .Release.Name }} release: {{ .Release.Name }}
component: server component: server
spec: spec:
strategy:
type: "RollingUpdate" #default
rollingUpdate:
maxSurge: 1
maxUnavailable: 0
#affinity: #affinity:
# podAntiAffinity: # podAntiAffinity:
# requiredDuringSchedulingIgnoredDuringExecution: # requiredDuringSchedulingIgnoredDuringExecution:
@ -75,6 +80,8 @@ spec:
fieldPath: metadata.namespace fieldPath: metadata.namespace
- name: VAULT_ADDR - name: VAULT_ADDR
value: "http://localhost:8200" value: "http://localhost:8200"
#- name: VAULT_TEST
#- value: "true"
command: command:
- "/bin/sh" - "/bin/sh"
- "-ec" - "-ec"
@ -97,24 +104,23 @@ spec:
preStop: preStop:
exec: exec:
command: command:
- vault step-down - vault operator step-down
ports: ports:
- containerPort: 8200 - containerPort: 8200
name: http name: http
#readinessProbe: readinessProbe:
# # NOTE(mitchellh): when our HTTP status endpoints support the # NOTE(mitchellh): when our HTTP status endpoints support the
# # proper status codes, we should switch to that. This is temporary. # proper status codes, we should switch to that. This is temporary.
# # TODO: verify for Vault # TODO: verify for Vault
# #exec: exec:
# # command: command:
# # - "/bin/sh" - "/bin/sh"
# # - "-ec" - "-ec"
# # - | - |
# # curl http://127.0.0.1:8500/v1/status/leader 2>/dev/null | \ vault status
# # grep -E '".+"' failureThreshold: 2
# failureThreshold: 2 initialDelaySeconds: 5
# initialDelaySeconds: 5 periodSeconds: 3
# periodSeconds: 3 successThreshold: 1
# successThreshold: 1 timeoutSeconds: 5
# timeoutSeconds: 5
{{- end }} {{- end }}

View file

@ -16,6 +16,12 @@ data "google_container_engine_versions" "main" {
zone = "${var.zone}" zone = "${var.zone}"
} }
#data "google_container_cluster" "cluster" {
# name = "cluster-1"
# zone = "${var.zone}"
# project = "${var.project}"
#}
resource "google_container_cluster" "cluster" { resource "google_container_cluster" "cluster" {
name = "vault-helm-dev-${random_id.suffix.dec}" name = "vault-helm-dev-${random_id.suffix.dec}"
project = "${var.project}" project = "${var.project}"