Skip to content

Commit 78aef5b

Browse files
authored
fix: update deployment workflows (#170)
* fix: update deployment workflows * fix: eslint issues
1 parent d9dd672 commit 78aef5b

15 files changed

Lines changed: 6798 additions & 7852 deletions

File tree

.github/workflows/deploy-dev.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ jobs:
1717
environment: development
1818
steps:
1919
- name: Checkout code
20-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2121

2222
- name: Yarn install and Cache dependencies
2323
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
2424

2525
- name: Yarn build
2626
# Set environment variables required to perform the build. These are only available to this step
2727
env:
28-
VITE_API_HOST: ${{ secrets.REACT_APP_API_HOST_DEV }}
28+
VITE_API_HOST: ${{ vars.VITE_API_HOST }}
2929
VITE_GRAASP_APP_KEY: ${{ secrets.APP_KEY }}
3030
VITE_SENTRY_ENV: development
3131
VITE_SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
@@ -43,6 +43,6 @@ jobs:
4343
version: 'latest'
4444
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_DEV }}
4545
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_DEV }}
46-
aws-region: ${{ secrets.APPS_AWS_REGION }}
47-
aws-s3-bucket-name: ${{ secrets.AWS_S3_BUCKET_NAME_APPS_DEV }}
46+
aws-region: ${{ vars.APPS_AWS_REGION_DEV }}
47+
aws-s3-bucket-name: ${{ vars.AWS_S3_BUCKET_NAME_APPS_DEV }}
4848
cloudfront-distribution-id: ${{ secrets.CLOUDFRONT_DISTRIBUTION_APPS_DEV }}

.github/workflows/deploy-prod.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
environment: production
1515
steps:
1616
- name: Checkout code
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4
1818
with:
1919
ref: ${{ github.event.client_payload.tag }}
2020

@@ -24,7 +24,7 @@ jobs:
2424
- name: Yarn build
2525
# Set environment variables required to perform the build. These are only available to this step
2626
env:
27-
VITE_API_HOST: ${{ secrets.REACT_APP_API_HOST_PROD }}
27+
VITE_API_HOST: ${{ vars.VITE_API_HOST }}
2828
VITE_GRAASP_APP_KEY: ${{ secrets.APP_KEY }}
2929
VITE_SENTRY_ENV: production
3030
VITE_SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
@@ -42,6 +42,6 @@ jobs:
4242
version: 'latest'
4343
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_PROD }}
4444
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_PROD }}
45-
aws-region: ${{ secrets.APPS_AWS_REGION }}
46-
aws-s3-bucket-name: ${{ secrets.AWS_S3_BUCKET_NAME_APPS_PROD }}
45+
aws-region: ${{ vars.APPS_AWS_REGION_PROD }}
46+
aws-s3-bucket-name: ${{ vars.AWS_S3_BUCKET_NAME_APPS_PROD }}
4747
cloudfront-distribution-id: ${{ secrets.CLOUDFRONT_DISTRIBUTION_APPS_PROD }}

.github/workflows/deploy-stage.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
environment: staging
1515
steps:
1616
- name: Checkout code
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4
1818
with:
1919
ref: ${{ github.event.client_payload.tag }}
2020

@@ -24,7 +24,7 @@ jobs:
2424
- name: Yarn build
2525
# Set environment variables required to perform the build. These are only available to this step
2626
env:
27-
VITE_API_HOST: ${{ secrets.REACT_APP_API_HOST_STAGE }}
27+
VITE_API_HOST: ${{ vars.VITE_API_HOST }}
2828
VITE_GRAASP_APP_KEY: ${{ secrets.APP_KEY }}
2929
VITE_SENTRY_ENV: staging
3030
VITE_SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
@@ -42,6 +42,6 @@ jobs:
4242
version: 'latest'
4343
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_STAGE }}
4444
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_STAGE }}
45-
aws-region: ${{ secrets.APPS_AWS_REGION }}
46-
aws-s3-bucket-name: ${{ secrets.AWS_S3_BUCKET_NAME_APPS_STAGE }}
45+
aws-region: ${{ vars.APPS_AWS_REGION_STAGE }}
46+
aws-s3-bucket-name: ${{ vars.AWS_S3_BUCKET_NAME_APPS_STAGE }}
4747
cloudfront-distribution-id: ${{ secrets.CLOUDFRONT_DISTRIBUTION_APPS_STAGE }}

.github/workflows/release-please.yml

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -8,23 +8,10 @@ jobs:
88
release-please:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: google-github-actions/release-please-action@v3
11+
- uses: google-github-actions/release-please-action@v4
1212
id: release
1313
with:
1414
release-type: node
15-
package-name: graasp-app-code-capsule
16-
changelog-types: '[{"type":"feat","section":"Features","hidden":false},{"type":"fix","section":"Bug Fixes","hidden":false},{"type":"docs","section":"Documentation","hidden":false},{"type":"test","section":"Tests","hidden":false}]'
17-
18-
- uses: actions/checkout@v3
19-
with:
20-
ref: main
21-
22-
- name: Tag major and minor versions
23-
uses: jacobsvante/tag-major-minor-action@v0.1
24-
if: ${{ steps.release.outputs.releases_created }}
25-
with:
26-
major: ${{ steps.release.outputs.major }}
27-
minor: ${{ steps.release.outputs.minor }}
2815

2916
- name: Set tag
3017
if: ${{ steps.release.outputs.releases_created }}
@@ -44,7 +31,7 @@ jobs:
4431
repository: graasp/graasp-deploy
4532
event-type: update-staging-version
4633
client-payload: ${{steps.set-tag.outputs.json}}
47-
34+
4835
- name: Auto Tag
4936
uses: graasp/graasp-deploy/.github/actions/auto-tag-after-release@v1
5037
with:

.yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

Lines changed: 0 additions & 546 deletions
This file was deleted.

.yarn/releases/yarn-3.6.3.cjs

Lines changed: 0 additions & 874 deletions
This file was deleted.

.yarn/releases/yarn-4.0.2.cjs

Lines changed: 893 additions & 0 deletions
Large diffs are not rendered by default.

.yarnrc.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1+
compressionLevel: mixed
2+
13
defaultSemverRangePrefix: ""
24

3-
nodeLinker: node-modules
5+
enableGlobalCache: false
46

5-
plugins:
6-
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
7-
spec: "@yarnpkg/plugin-interactive-tools"
7+
nodeLinker: node-modules
88

9-
yarnPath: .yarn/releases/yarn-3.6.3.cjs
9+
yarnPath: .yarn/releases/yarn-4.0.2.cjs

cypress.config.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import registerCodeCoverageTask from '@cypress/code-coverage/task';
12
import { defineConfig } from 'cypress';
23

34
export default defineConfig({
@@ -13,7 +14,7 @@ export default defineConfig({
1314
// We've imported your old cypress plugins here.
1415
// You may want to clean this up later by importing these.
1516
setupNodeEvents(on, config) {
16-
require('@cypress/code-coverage/task')(on, config);
17+
registerCodeCoverageTask(on, config);
1718
return config;
1819
},
1920
baseUrl: `http://localhost:${process.env.VITE_PORT || 3000}`,

0 commit comments

Comments
 (0)