mirror of
https://github.com/immich-app/static-pages.git
synced 2026-09-30 13:23:05 +08:00
43 lines
1.6 KiB
YAML
43 lines
1.6 KiB
YAML
name: Docs destroy
|
|
on:
|
|
pull_request_target:
|
|
types: [closed]
|
|
|
|
env:
|
|
MISE_TRUSTED_CONFIG_PATHS: ${{ github.workspace }}/.mise/config.toml
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
environment: ['dev', 'prod']
|
|
app_name: ['root', 'ui', 'api', 'awesome', 'my', 'get', 'buy', 'datasets']
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
|
|
|
- name: Setup Mise
|
|
uses: immich-app/devtools/actions/use-mise@035e80a7d4355d5f087ffb95db9e4a0944c04e56 # use-mise-action-v1.1.3
|
|
|
|
- name: Install 1Password CLI
|
|
uses: 1password/install-cli-action@8d006a0d0a4fd505af7f7ce589e7f768385ff5e4 # v3.0.0
|
|
|
|
- name: Destroy All
|
|
working-directory: ${{ github.workspace }}/deployment
|
|
env:
|
|
ENVIRONMENT: ${{ matrix.environment }}
|
|
TF_VAR_app_name: ${{ matrix.app_name }}
|
|
TF_VAR_dist_dir: ${{ github.workspace }}/apps/${{ matrix.app_name }}.immich.app/backend/dist
|
|
TF_VAR_stage: pr-${{ github.event.number }}
|
|
OP_SERVICE_ACCOUNT_TOKEN: ${{ matrix.environment == 'prod' && secrets.OP_TF_PROD_ENV || secrets.OP_TF_DEV_ENV }}
|
|
run: op run --env-file=".env" -- terragrunt run --all destroy --non-interactive --queue-exclude-dir '**/pages-project' -- -refresh=false -lock-timeout=5m
|
|
|
|
- name: Comment
|
|
uses: actions-cool/maintain-one-comment@909842216bc8e8658364c572ec52100f4c2cc50a # v3.3.0
|
|
with:
|
|
number: ${{ github.event.number }}
|
|
delete: true
|
|
body-include: '<!-- Docs PR URL -->'
|