Skip to content

Commit 0813238

Browse files
authored
Update deploy-production.yml
Fix cache handling
1 parent 96b0e41 commit 0813238

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

.github/workflows/deploy-production.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
name: Deploy production from main
2-
32
on:
43
push:
54
branches: [main]
6-
75
env:
86
NODE_VERSION: "18.x"
9-
107
concurrency: production-environment
118

129
jobs:
@@ -15,18 +12,21 @@ jobs:
1512
runs-on: ubuntu-latest
1613
environment: production
1714
steps:
18-
- uses: actions/checkout@v2
15+
- uses: actions/checkout@v3
16+
1917
- name: Use Node.js ${{ env.NODE_VERSION }}
20-
uses: actions/setup-node@v1
18+
uses: actions/setup-node@v3
2119
with:
2220
node-version: ${{ env.NODE_VERSION }}
23-
- name: yarn build
21+
cache: 'yarn' # <-- NEW: Enable Yarn caching automatically
22+
23+
- name: Install dependencies and build
2424
env:
25-
# The license needs to present when building, so that the admin-ui is built as enterprise version
2625
STRAPI_LICENSE: ${{ secrets.STRAPI_LICENSE }}
2726
run: |
2827
yarn install --silent
2928
yarn build
29+
3030
- name: Deploy to Azure webApp
3131
uses: azure/webapps-deploy@v3
3232
with:

0 commit comments

Comments
 (0)