From abbaf8a3426882f2513120a10cf8b361a3ed22e5 Mon Sep 17 00:00:00 2001 From: multipleof4 Date: Thu, 11 Sep 2025 02:29:52 -0700 Subject: [PATCH] Update deploy.yml --- .github/workflows/deploy.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 43b0a33..6b7cbd5 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -11,10 +11,12 @@ jobs: runs-on: ubuntu-latest env: FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} + GITEA_APP_NAME: ${{ secrets.FLY_APP_NAME }} + RUNNER_APP_NAME: ${{ secrets.RUNNER_APP_NAME }} steps: - uses: actions/checkout@v4 - uses: superfly/flyctl-actions/setup-flyctl@master - if: github.event.inputs.app == 'gitea' - run: flyctl apps create ${{ secrets.FLY_APP_NAME }} || true; flyctl volumes create gitea_data --size 1 -a ${{ secrets.FLY_APP_NAME }} || true; flyctl deploy --remote-only -a ${{ secrets.FLY_APP_NAME }} -c fly.toml --build-arg GITEA_APP_NAME=${{ secrets.FLY_APP_NAME }} + run: flyctl apps create $GITEA_APP_NAME --org personal || true; flyctl volumes create gitea_data --size 1 -a $GITEA_APP_NAME || true; flyctl secrets set GITEA__server__DOMAIN=$GITEA_APP_NAME.fly.dev GITEA__server__ROOT_URL=https://$GITEA_APP_NAME.fly.dev -a $GITEA_APP_NAME; flyctl deploy --remote-only -a $GITEA_APP_NAME -c fly.toml - if: github.event.inputs.app == 'runner' - run: flyctl apps create ${{ secrets.RUNNER_APP_NAME }} || true; flyctl volumes create runner_data --size 1 -a ${{ secrets.RUNNER_APP_NAME }} || true; flyctl secrets set GITEA_RUNNER_REGISTRATION_TOKEN='${{ secrets.GITEA_RUNNER_REGISTRATION_TOKEN }}' -a ${{ secrets.RUNNER_APP_NAME }}; flyctl deploy --remote-only -a ${{ secrets.RUNNER_APP_NAME }} -c runner/fly.toml --build-arg GITEA_INSTANCE_URL=https://${{ secrets.FLY_APP_NAME }}.fly.dev + run: flyctl apps create $RUNNER_APP_NAME --org personal || true; flyctl volumes create runner_data --size 1 -a $RUNNER_APP_NAME || true; flyctl secrets set GITEA_INSTANCE_URL=https://$GITEA_APP_NAME.fly.dev GITEA_RUNNER_REGISTRATION_TOKEN='${{ secrets.GITEA_RUNNER_REGISTRATION_TOKEN }}' -a $RUNNER_APP_NAME; flyctl deploy --remote-only -a $RUNNER_APP_NAME -c runner/fly.toml