gowalk-cicd 1.0.38 → 1.0.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CLAUDE.md CHANGED
@@ -101,6 +101,9 @@ node /path/to/gowalk-cicd/bin/cli.mjs
101
101
  - Backend runtime credentials use the single encrypted `BACKEND_RUNTIME_ENV`
102
102
  secret. The action writes it to host-side `.runtime.env` with mode 0600 and
103
103
  supplies it to Compose after the generated `.env`; never print its content.
104
+ - The mobile workflow's feature-branch-only `backend-preview` job bootstraps a
105
+ new app before GitHub registers `deploy-backend.yml` on the default branch.
106
+ Default-branch deploys continue through the separate backend workflow.
104
107
  - The Android action serves two build systems. `android_config.project_kind()`
105
108
  is the only place that decides which; every downstream step branches on the
106
109
  `project_kind` output rather than re-sniffing the repo. Flutter wins the tie
package/README.md CHANGED
@@ -72,6 +72,11 @@ Requirements on the consumer repo:
72
72
  The action directory is canonical here (like the iOS/Android actions): edit it in
73
73
  `backend-action/`, never in a consumer's vendored copy.
74
74
 
75
+ For a new app whose separate backend workflow is not registered on the default
76
+ branch yet, manually dispatching **Mobile Deploy** on the feature branch runs
77
+ the same backend action as a `backend-preview` job. The job is feature-branch
78
+ only; normal default-branch backend deploys remain in `deploy-backend.yml`.
79
+
75
80
  ## Android credentials
76
81
 
77
82
  Place these files under `creds/`:
@@ -1 +1 @@
1
- 1.0.38
1
+ 1.0.39
@@ -1 +1 @@
1
- 1.0.38
1
+ 1.0.39
@@ -1 +1 @@
1
- 1.0.38
1
+ 1.0.39
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gowalk-cicd",
3
- "version": "1.0.38",
3
+ "version": "1.0.39",
4
4
  "description": "Zero-config GitHub Actions delivery for iOS TestFlight and Android Google Play.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -397,3 +397,35 @@ jobs:
397
397
  uploaded without being submitted. Open Play Console for \
398
398
  ${{ steps.android.outputs.package-name }} and press 'Send changes for review' on the \
399
399
  Publishing overview page. This is normal after a policy rejection."
400
+
401
+ # GitHub only registers a newly added workflow after it reaches the default
402
+ # branch. A brand-new app's feature branch therefore cannot dispatch the
403
+ # separate Backend Deploy workflow yet. Reuse this already-registered mobile
404
+ # workflow for the first feature-branch deploy; default-branch pushes keep
405
+ # using deploy-backend.yml and never run this job twice.
406
+ backend-preview:
407
+ name: Backend Deploy
408
+ if: >-
409
+ ${{ github.event_name == 'workflow_dispatch'
410
+ && github.ref_name != github.event.repository.default_branch }}
411
+ runs-on: ubuntu-latest
412
+ timeout-minutes: 30
413
+ steps:
414
+ - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
415
+ - id: dir
416
+ shell: bash
417
+ run: |
418
+ if [ -f backend/docker-compose.yml ]; then echo "path=backend" >> "$GITHUB_OUTPUT"
419
+ elif [ -f server/docker-compose.yml ]; then echo "path=server" >> "$GITHUB_OUTPUT"
420
+ else echo "path=" >> "$GITHUB_OUTPUT"; fi
421
+ - name: Deploy backend from feature branch
422
+ if: ${{ steps.dir.outputs.path != '' }}
423
+ uses: ./.github/actions/backend-app
424
+ with:
425
+ ssh-key: ${{ secrets.BACKEND_DEPLOY_SSH_KEY }}
426
+ host: ${{ vars.BACKEND_DEPLOY_HOST || '138.197.36.107' }}
427
+ app-name: ${{ vars.BACKEND_APP_NAME || github.event.repository.name }}
428
+ api-domain: ${{ vars.BACKEND_API_DOMAIN }}
429
+ backend-dir: ${{ steps.dir.outputs.path }}
430
+ health-path: ${{ vars.BACKEND_HEALTH_PATH || '/health' }}
431
+ runtime-env: ${{ secrets.BACKEND_RUNTIME_ENV }}