feat(Illustration): new illustration interlink #4107
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Teardown Pull Request | |
on: | |
pull_request: | |
types: [closed] | |
jobs: | |
teardown: | |
runs-on: ubuntu-22.04 | |
env: | |
IMAGE_NAME: rg.fr-par.scw.cloud/ultraviolet/storybook | |
STORYBOOK_DEPLOYMENT_NAME: storybook | |
SCW_DNS: ${{ github.ref_name == 'main' && 'storybook.ultraviolet.scaleway.com' || '' }} | |
steps: | |
- uses: actions/checkout@v4 # v4.1.4 | |
- name: Inject slug/short variables | |
uses: rlespinasse/github-slug-action@v4 | |
- name: Export custom variables | |
run: | | |
SAFE_GITHUB_HEAD_REF_SLUG_URL=$(echo $GITHUB_HEAD_REF_SLUG_URL-$STORYBOOK_DEPLOYMENT_NAME | rev | cut -c-37 | rev | awk '{gsub(/^-/, ""); print}') | |
echo "STORYBOOK_BRANCH_SLUG=$SAFE_GITHUB_HEAD_REF_SLUG_URL" >> $GITHUB_ENV | |
- name: Deploy Serverless Container Scaleway | |
uses: philibea/[email protected] | |
id: deploy | |
with: | |
type: "teardown" | |
scw_dns: ${{ env.SCW_DNS }} | |
scw_access_key: ${{ secrets.SCW_ACCESS_KEY }} | |
scw_secret_key: ${{ secrets.SCW_SECRET_KEY }} | |
scw_containers_namespace_id: ${{ secrets.SCW_CONTAINERS_NAMESPACE_ID }} | |
scw_registry: ${{ env.IMAGE_NAME }}:${{ env.STORYBOOK_BRANCH_SLUG }} | |
- name: Remove storybook deployment | |
uses: bobheadxi/[email protected] | |
with: | |
step: deactivate-env | |
token: ${{ secrets.GITHUB_TOKEN }} | |
env: ${{ env.STORYBOOK_BRANCH_SLUG }} |