Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.

Commit

Permalink
Fix for postgres bringup failure
Browse files Browse the repository at this point in the history
  • Loading branch information
barney-s committed Jan 27, 2019
1 parent 8eebde9 commit 2eb7176
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 15 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,6 @@ docker-push: docker-build


e2e-test:
kubectl get namespace airflowop-system || kubectl create namespace airflowop-system
go test -v -timeout 20m test/e2e/base_test.go --namespace airflowop-system
go test -v -timeout 20m test/e2e/cluster_test.go --namespace airflowop-system
2 changes: 0 additions & 2 deletions templates/postgres-sts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ spec:
{{end}}
containers:
- name: postgres
args:
- --explicit-defaults-for-timestamp=ON
env:
- name: POSTGRES_DB
value: testdb
Expand Down
24 changes: 11 additions & 13 deletions test/e2e/base_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,17 +83,15 @@ var _ = Describe(CRName+" controller tests", func() {
ctx.WithTimeout(100).CheckCR(isBaseReady)
})

/*
It("creating a "+CRName+" with postgres", func() {
ctx = f.NewContext().WithCR(airflowBase(SampleDir + "postgres-celery/base.yaml"))
cr := ctx.CR.(*v1alpha1.AirflowBase)
By("creating a new " + CRName + ": " + cr.Name)
ctx.CreateCR()
ctx.WithTimeout(200).CheckStatefulSet(cr.Name+"-postgres", 1, 1)
ctx.WithTimeout(10).CheckService(cr.Name+"-sql", map[string]int32{"postgres": 5432})
//ctx.WithTimeout(10).CheckSecret(name)
ctx.WithTimeout(200).CheckStatefulSet(cr.Name+"-nfs", 1, 1)
ctx.WithTimeout(100).CheckCR(isBaseReady)
})
*/
It("creating a "+CRName+" with postgres", func() {
ctx = f.NewContext().WithCR(airflowBase(SampleDir + "postgres-celery/base.yaml"))
cr := ctx.CR.(*v1alpha1.AirflowBase)
By("creating a new " + CRName + ": " + cr.Name)
ctx.CreateCR()
ctx.WithTimeout(200).CheckStatefulSet(cr.Name+"-postgres", 1, 1)
ctx.WithTimeout(10).CheckService(cr.Name+"-sql", map[string]int32{"postgres": 5432})
//ctx.WithTimeout(10).CheckSecret(name)
ctx.WithTimeout(200).CheckStatefulSet(cr.Name+"-nfs", 1, 1)
ctx.WithTimeout(100).CheckCR(isBaseReady)
})
})

0 comments on commit 2eb7176

Please sign in to comment.