name: "Deploy one (web)" on: workflow_dispatch: inputs: app: description: "App to build and deploy" type: choice required: true default: "photos" options: - "accounts" - "auth" - "cast" - "payments" - "photos" permissions: contents: read jobs: deploy: runs-on: ubuntu-latest defaults: run: working-directory: web steps: - name: Checkout code uses: actions/checkout@v4 - name: Setup node and enable yarn caching uses: actions/setup-node@v4 with: node-version: 22 cache: "yarn" cache-dependency-path: "web/yarn.lock" - name: Install dependencies run: yarn install - name: Build ${{ inputs.app }} run: yarn build:${{ inputs.app }} - name: Publish ${{ inputs.app }} to preview uses: cloudflare/wrangler-action@v3 with: accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} # [Note: Wrangler commit-dirty] # # Without the --commit-dirty flag, running the wrangler-action # always prints a warning when used: # # Warning: Your working directory is a git repo and has uncommitted changes # To silence this warning, pass in --commit-dirty=true # # There is no clear documentation of if passing this is # harmless, but all indications and in-practice tests seem to # indicate so. command: pages deploy --project-name=ente --commit-dirty=true --branch=deploy/${{ inputs.app }} web/apps/${{ inputs.app }}/out