-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Tao Li <[email protected]>
- Loading branch information
Showing
1 changed file
with
76 additions
and
0 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 |
---|---|---|
|
@@ -12,6 +12,7 @@ jobs: | |
outputs: | ||
pg4k-pgd-changed: ${{ steps.filter.outputs.pg4k-pgd-changed }} | ||
ep4k-changed: ${{ steps.filter.outputs.ep4k-changed }} | ||
ep4k-lts-changed: ${{ steps.filter.outputs.ep4k-lts-changed }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
|
@@ -26,6 +27,8 @@ jobs: | |
- 'charts/edb-postgres-distributed-for-kubernetes/**' | ||
ep4k-changed: | ||
- 'charts/edb-postgres-for-kubernetes/**' | ||
ep4k-lts-changed: | ||
- 'charts/edb-postgres-distributed-for-kubernetes/charts/edb-postgres-for-kubernetes-lts/**' | ||
deploy-ep4k: | ||
runs-on: ubuntu-22.04 | ||
|
@@ -61,6 +64,40 @@ jobs: | |
PHASE="Cluster in healthy state" | ||
kubectl wait --timeout=5m --for=jsonpath='{.status.phase}'="$PHASE" clusters/cluster-example | ||
deploy-ep4k-lts: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- change-triage | ||
if: needs.change-triage.outputs.ep4k-lts-changed == 'true' | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Helm | ||
uses: azure/setup-helm@v4 | ||
with: | ||
version: v3.11.3 | ||
|
||
- name: Create kind cluster | ||
uses: helm/[email protected] | ||
|
||
- name: Deploy using helm chart | ||
run: | | ||
helm upgrade --install edb-pg4k-lts --namespace postgresql-operator-system \ | ||
--create-namespace charts/edb-postgres-distributed-for-kubernetes/charts/edb-postgres-for-kubernetes-lts --wait | ||
- name: Install kubectl | ||
uses: azure/setup-kubectl@v4 | ||
|
||
- name: Deploy a cluster | ||
run: | | ||
kubectl apply -f hack/samples/ep4k-cluster.yaml | ||
PHASE="Cluster in healthy state" | ||
kubectl wait --timeout=5m --for=jsonpath='{.status.phase}'="$PHASE" clusters/cluster-example | ||
deploy-pg4k-pgd: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
|
@@ -141,3 +178,42 @@ jobs: | |
kubectl create ns test-ignore | ||
kubectl -n test-ignore apply -f hack/samples/ep4k-cluster.yaml | ||
kubectl -n test-ignore get pods 2>&1 >/dev/null | grep 'No resources found' | ||
deploy-ep4k-lts-single-namespace: | ||
runs-on: ubuntu-22.04 | ||
needs: | ||
- change-triage | ||
if: needs.change-triage.outputs.ep4k-lts-changed == 'true' | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Helm | ||
uses: azure/setup-helm@v4 | ||
with: | ||
version: v3.11.3 | ||
|
||
- name: Create kind cluster | ||
uses: helm/[email protected] | ||
|
||
- name: Deploy in single-namespace mode using helm chart | ||
run: | | ||
helm upgrade --install edb-pg4k-lts --namespace single-install \ | ||
--set config.clusterWide=false \ | ||
--create-namespace charts/edb-postgres-distributed-for-kubernetes/charts/edb-postgres-for-kubernetes-lts --wait | ||
- name: Install kubectl | ||
uses: azure/setup-kubectl@v4 | ||
|
||
- name: Deploy a cluster in the watched namespace | ||
run: | | ||
kubectl -n single-install apply -f hack/samples/ep4k-cluster.yaml | ||
PHASE="Cluster in healthy state" | ||
kubectl -n single-install wait --timeout=5m --for=jsonpath='{.status.phase}'="$PHASE" clusters/cluster-example | ||
- name: Ignore deploying a cluster in another namespace | ||
run: | | ||
kubectl create ns test-ignore | ||
kubectl -n test-ignore apply -f hack/samples/ep4k-cluster.yaml | ||
kubectl -n test-ignore get pods 2>&1 >/dev/null | grep 'No resources found' |