Skip to content

Commit

Permalink
fix: Dockerfile and template for db, drop frontend (#48)
Browse files Browse the repository at this point in the history
* Dockerfile and template for db, drop frontend

* Remove frontend refs

* Main merge workflow updates
  • Loading branch information
DerekRoberts authored Oct 30, 2023
1 parent b1777b1 commit 1a9d735
Show file tree
Hide file tree
Showing 4 changed files with 375 additions and 27 deletions.
15 changes: 2 additions & 13 deletions .github/workflows/merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,11 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
name: [database, backend-go, backend-java, backend-py, frontend]
name: [database, backend-go, backend-java, backend-py]
include:
- name: database
file: database/openshift.deploy.yml
overwrite: false
repository: bcgov/quickstart-openshift
- name: backend-go
file: backend-go/openshift.deploy.yml
overwrite: true
Expand All @@ -36,10 +35,6 @@ jobs:
file: backend-py/openshift.deploy.yml
overwrite: true
parameters: -p PROMOTE_MIGRATION=${{ github.repository }}/migrations-py:test
- name: frontend
file: frontend/openshift.deploy.yml
overwrite: true
repository: bcgov/quickstart-openshift
steps:
- uses: bcgov-nr/action-deployer-openshift@v2.0.0
with:
Expand Down Expand Up @@ -121,12 +116,11 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
name: [database, backend-go, backend-java, backend-py, frontend]
name: [database, backend-go, backend-java, backend-py]
include:
- name: database
file: database/openshift.deploy.yml
overwrite: false
repository: bcgov/quickstart-openshift
- name: backend-go
file: backend-go/openshift.deploy.yml
overwrite: true
Expand All @@ -141,11 +135,6 @@ jobs:
overwrite: true
parameters: -p MIN_REPLICAS=1 -p MAX_REPLICAS=2
-p PROMOTE_MIGRATION=${{ github.repository }}/migrations-py:test
- name: frontend
file: frontend/openshift.deploy.yml
overwrite: true
parameters: -p MIN_REPLICAS=1 -p MAX_REPLICAS=2
repository: bcgov/quickstart-openshift
steps:
- uses: bcgov-nr/action-deployer-openshift@v2.0.0
with:
Expand Down
18 changes: 4 additions & 14 deletions .github/workflows/pr-open.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ jobs:
Thanks for the PR!
Deployments, as required, will be available below:
- [Frontend](https://${{ env.PREFIX }}-frontend.${{ env.DOMAIN }})
- [Backend](https://${{ env.PREFIX }}-backend.${{ env.DOMAIN }})
- [Backend-java](https://${{ env.PREFIX }}-backend-java.${{ env.DOMAIN }})
- [Backend-py](https://${{ env.PREFIX }}-backend-py.${{ env.DOMAIN }})
Expand All @@ -53,10 +52,10 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
package: [database, backend-go, backend-java, backend-py, migrations-go, migrations-py, frontend]
package: [database, backend-go, backend-java, backend-py, migrations-go, migrations-py]
include:
- package: database
repository: bcgov/quickstart-openshift
triggers: ('database/')
- package: backend-go
triggers: ('backend-go/')
- package: backend-java
Expand All @@ -69,8 +68,6 @@ jobs:
- package: migrations-go
triggers: ('backend-go/db')
build_context: ./backend-go/db
- package: frontend
repository: bcgov/quickstart-openshift
steps:
- uses: bcgov-nr/action-builder-ghcr@v1.3.0
with:
Expand All @@ -92,13 +89,12 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
name: [database, backend-go, backend-java, backend-py, frontend]
name: [database, backend-go, backend-java, backend-py]
include:
- name: database
file: database/openshift.deploy.yml
overwrite: false
repository: bcgov/quickstart-openshift
triggers: ('backend-go' 'backend-java' 'backend-py')
triggers: ('database' 'backend-go' 'backend-java' 'backend-py')
- name: backend-go
file: backend-go/openshift.deploy.yml
overwrite: true
Expand All @@ -119,12 +115,6 @@ jobs:
-p PROMOTE=${{ github.repository }}/backend-py:${{ github.event.number }}
-p PROMOTE_MIGRATION=${{ github.repository }}/migrations-py:${{ github.event.number }}
triggers: ('backend-py/')
- name: frontend
file: frontend/openshift.deploy.yml
overwrite: true
parameters: -p MIN_REPLICAS=1 -p MAX_REPLICAS=2
repository: bcgov/quickstart-openshift
triggers: ('database/' 'backend/' 'frontend/')
steps:
- uses: bcgov-nr/action-deployer-openshift@v2.0.0
with:
Expand Down
5 changes: 5 additions & 0 deletions database/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM ghcr.io/bcgov/nr-containers/postgres:15.4

# Health check and non-privileged user
HEALTHCHECK --interval=15s --timeout=5s --retries=3 CMD [ "pg_isready" ]
USER postgres
Loading

0 comments on commit 1a9d735

Please sign in to comment.