-
Notifications
You must be signed in to change notification settings - Fork 43
38 lines (32 loc) · 967 Bytes
/
frontend.main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: deploy_frontend
# Deploys when push is made from frontend folder
on:
push:
branches: [ main ]
paths:
- 'frontend/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: login with azure
uses: azure/login@v1
with:
creds: ${{ secrets.AZURE_CREDENTIALS }}
- name: Upload to blob storage
uses: azure/CLI@v1
with:
azcliversion: 2.30.0
inlineScript: |
az storage blob upload-batch --account-name cloudresumesite -d '$web' -s frontend/
- name: Purge CDN endpoint
uses: azure/CLI@v1
with:
azcliversion: 2.30.0
inlineScript: |
az cdn endpoint purge --content-paths "/*" --profile-name "CloudResumeChallengeGPS" --name "cloudresumechallengegps" --resource-group "cloud-resume-challenge-rg"
# Azure logout
- name: logout
run: |
az logout