Skip to content

Commit 1025bb2

Browse files
committed
ADD: prod configurations
1 parent d2cdf0a commit 1025bb2

File tree

4 files changed

+18
-9
lines changed

4 files changed

+18
-9
lines changed

.github/workflows/cd-workflow.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ jobs:
9999
with:
100100
project_id: ${{ secrets.GCP_PROJECT_ID }}
101101

102+
102103
- name: Deploy to Cloud Run
103104
id: deploy
104105
uses: google-github-actions/deploy-cloudrun@v1
@@ -110,3 +111,8 @@ jobs:
110111
flags: >
111112
--allow-unauthenticated
112113
--port=7007
114+
--add-cloudsql-instances=${{ secrets.GCP_SQL_CONNECTION_NAME }}
115+
env_vars: |
116+
POSTGRES_HOST=/cloudsql/${{ secrets.GCP_SQL_CONNECTION_NAME }}
117+
POSTGRES_PORT=5432
118+
# BASE_URL=https://backstage.foundations-software-engineering.com

Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ ARG APP_ENV
120120
COPY --chown=node:node app-config.yaml ./
121121
COPY --chown=node:node app-config.docker.yaml ./app-config.docker.yaml
122122
COPY --chown=node:node app-config.${APP_ENV}.yaml ./app-config.env.yaml
123+
COPY --chown=node:node app-config.production.yaml ./app-config.production.yaml
123124

124125
# This will include the examples, if you don't need these simply remove this line
125126
COPY --chown=node:node examples ./examples

app-config.production.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,17 @@ backend:
77
origin: https://backstage-deployment-1006240973223.europe-west10.run.app
88
methods: [GET, HEAD, PATCH, POST, PUT, DELETE]
99
credentials: true
10+
database:
11+
client: pg
12+
connection:
13+
host: ${POSTGRES_HOST}
14+
port: ${POSTGRES_PORT}
15+
user: ${POSTGRES_USER}
16+
password: ${POSTGRES_PASSWORD}
17+
plugin:
18+
auth:
19+
connection:
20+
database: ${POSTGRES_DB}
1021

1122
auth:
1223
environment: production

app-config.yaml

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,6 @@ backend:
1515
origin: http://localhost:3000
1616
methods: [GET, HEAD, PATCH, POST, PUT, DELETE]
1717
credentials: true
18-
database:
19-
client: pg
20-
connection:
21-
host: ${POSTGRES_HOST}
22-
port: ${POSTGRES_PORT}
23-
user: ${POSTGRES_USER}
24-
password: ${POSTGRES_PASSWORD}
25-
cache:
26-
store: memory
2718

2819
integrations:
2920
github:

0 commit comments

Comments
 (0)