Skip to content

Commit

Permalink
Merge pull request #7 from EnterpriseDB/cnp-cnpg
Browse files Browse the repository at this point in the history
chore: cnp -> cnpg
  • Loading branch information
trinchan authored Jul 25, 2023
2 parents 87e43be + d4c326b commit b10cec8
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 29 deletions.
36 changes: 18 additions & 18 deletions .github/workflows/cicd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,10 @@ jobs:
push: true
provenance: false
tags: |
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:latest
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.fullversion }}
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:latest
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.fullversion }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }}
build-args: |
TAG=${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }}
- name: Pull CNPG image
Expand All @@ -68,14 +68,14 @@ jobs:
- name: Tag CNPG image
if: ${{ github.event_name != 'workflow_dispatch' }}
run: |
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:latest
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.fullversion }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:latest
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.fullversion }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser.outputs.major }}.${{ steps.semver_parser.outputs.minor }}.${{ steps.semver_parser.outputs.patch }}
- name: Push CNPG image tags
if: ${{ github.event_name != 'workflow_dispatch' }}
run: |
docker image push --all-tags gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg
docker image push --all-tags gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg
#####

# Steps to run on dispatch
Expand All @@ -99,10 +99,10 @@ jobs:
push: true
provenance: false
tags: |
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:latest
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.fullversion }}
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}
gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:latest
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.fullversion }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}
gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/deployer:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }}
build-args: |
TAG=${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }}
- name: Pull CNPG image
Expand All @@ -112,12 +112,12 @@ jobs:
- name: Tag CNPG image
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:latest
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.fullversion }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:latest
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.fullversion }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}
docker tag ghcr.io/cloudnative-pg/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }} gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg:${{ steps.semver_parser_dispatch.outputs.major }}.${{ steps.semver_parser_dispatch.outputs.minor }}.${{ steps.semver_parser_dispatch.outputs.patch }}
- name: Push CNPG image tags
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
docker image push --all-tags gcr.io/public-edb-ppas/edb-cnp-gke-autopilot-dev/cloudnative-pg
docker image push --all-tags gcr.io/public-edb-ppas/edb-cnpg-gke-autopilot-dev/cloudnative-pg
#####
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
APP_NAME := edb-cnp-gke-autopilot
APP_NAME_DEV := edb-cnp-gke-autopilot-dev
APP_NAME := edb-cnpg-gke-autopilot
APP_NAME_DEV := edb-cnpg-gke-autopilot-dev
REGISTRY := gcr.io/public-edb-ppas
TAG ?= 1.20.0
DOCKER_BUILDKIT := 1
Expand Down Expand Up @@ -66,19 +66,19 @@ cnpg-push-prod: ## Push the cnpg image to the production project
.PHONY: update-chart
update-chart: ## Update the CNPG dependency chart
helm repo add cnpg https://cloudnative-pg.github.io/charts
helm dependency build chart/edb-cnp-gke-autopilot
helm dependency build chart/edb-cnpg-gke-autopilot

.PHONY: install
install: ## Install the deployer image via mpdev
mpdev install \
--deployer=${REGISTRY}/${APP_NAME_DEV}/deployer:${TAG} \
--parameters='{"name": "edb-cnp-gke-autopilot-test","namespace": "cnpg-system","metering.reportingSecret": "fake-reporting-secret"}'
--parameters='{"name": "edb-cnpg-gke-autopilot-test","namespace": "cnpg-system","metering.reportingSecret": "fake-reporting-secret"}'

.PHONY: install-prod
install-prod: ## Install the deployer image via mpdev
mpdev install \
--deployer=${REGISTRY}/${APP_NAME}/deployer:${TAG} \
--parameters='{"name": "edb-cnp-gke-autopilot-test","namespace": "cnpg-system","metering.reportingSecret": "fake-reporting-secret"}'
--parameters='{"name": "edb-cnpg-gke-autopilot-test","namespace": "cnpg-system","metering.reportingSecret": "fake-reporting-secret"}'

.PHONY: verify-install
verify-install: ## Run the Marketplace verifier
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ gcloud container clusters get-credentials "${CLUSTER}" --zone "${ZONE}"
Clone this repo and its associated tools repo:

```shell
git clone --recursive https://github.com/EnterpriseDB/edb-cnp-gke-autopilot-deployer.git
git clone --recursive https://github.com/EnterpriseDB/edb-cnpg-gke-autopilot-deployer.git
```

#### Install the Application resource definition
Expand All @@ -103,7 +103,7 @@ The source code can be found on [github.com/kubernetes-sigs/application](https:/
Navigate to the `edb-cnp-gke-autopilot-deployer` directory:

```shell
cd edb-cnp-gke-autopilot-deployer
cd edb-cnpg-gke-autopilot-deployer
```

#### Configure the app with environment variables
Expand Down Expand Up @@ -209,7 +209,7 @@ Use `helm template` to expand the template. We recommend that you save the
expanded manifest file for future updates to the app.

```shell
helm template "${APP_INSTANCE_NAME}" chart/edb-cnp-gke-autopilot\
helm template "${APP_INSTANCE_NAME}" chart/edb-cnpg-gke-autopilot\
--namespace "${NAMESPACE}" \
--set cloudnative-pg.image.repository="${IMAGE_OPERATOR}" \
--set cloudnative-pg.image.tag="${TAG}" \
Expand Down
2 changes: 1 addition & 1 deletion chart/edb-cnp-gke-autopilot/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
engine: gotpl
name: edb-cnp-gke-autopilot
name: edb-cnpg-gke-autopilot
version: 1.0.0
4 changes: 2 additions & 2 deletions chart/edb-cnp-gke-autopilot/values.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cloudnative-pg:
podLabels:
app: edb-cnp-gke-autopilot
app: edb-cnpg-gke-autopilot
serviceAccount:
create: false
rbac:
Expand Down Expand Up @@ -31,7 +31,7 @@ metering:
pullPolicy: IfNotPresent
reportingSecret: ""
labels:
app: edb-cnp-gke-autopilot-metering
app: edb-cnpg-gke-autopilot-metering
secretName: ""
serviceAccountName: ""
podSecurityContext:
Expand Down

0 comments on commit b10cec8

Please sign in to comment.