mirror of
https://github.com/logto-io/logto.git
synced 2024-12-16 20:26:19 -05:00
ci: deploy to staging slot and swap (#3501)
This commit is contained in:
parent
2dbf6e26be
commit
998be42978
1 changed files with 10 additions and 0 deletions
10
.github/workflows/release.yml
vendored
10
.github/workflows/release.yml
vendored
|
@ -176,14 +176,24 @@ jobs:
|
|||
uses: azure/webapps-deploy@v2
|
||||
with:
|
||||
app-name: ${{ vars.APP_NAME_CORE }}
|
||||
slot-name: staging
|
||||
images: ghcr.io/logto-io/logto:sha-${{ steps.sha.outputs.short }}
|
||||
|
||||
- name: Deploy cloud to containerapp
|
||||
uses: azure/webapps-deploy@v2
|
||||
with:
|
||||
app-name: ${{ vars.APP_NAME_CLOUD }}
|
||||
slot-name: staging
|
||||
images: ghcr.io/logto-io/cloud:sha-${{ steps.sha.outputs.short }}
|
||||
|
||||
- name: Swap core to production
|
||||
# See https://learn.microsoft.com/en-us/cli/azure/webapp/deployment/slot?view=azure-cli-latest#az-webapp-deployment-slot-swap
|
||||
run: az webapp deployment slot swap -g ${{ vars.RESOURCE_GROUP }} -n ${{ vars.APP_NAME_CORE }} --slot staging
|
||||
|
||||
- name: Swap cloud to production
|
||||
# See https://learn.microsoft.com/en-us/cli/azure/webapp/deployment/slot?view=azure-cli-latest#az-webapp-deployment-slot-swap
|
||||
run: az webapp deployment slot swap -g ${{ vars.RESOURCE_GROUP }} -n ${{ vars.APP_NAME_CLOUD }} --slot staging
|
||||
|
||||
# Publish packages and create git tags if needed
|
||||
publish-and-tag:
|
||||
runs-on: ubuntu-latest
|
||||
|
|
Loading…
Reference in a new issue