2026-05-06 08:07:28 -05:00
|
|
|
name: Publish Site
|
2026-08-29 21:22:04 +00:00
|
|
|
description: Build and deploy one or more routed static-content artifacts to Garage S3 with Traefik and cert-manager.
|
2026-05-06 08:07:28 -05:00
|
|
|
inputs:
|
|
|
|
|
token:
|
|
|
|
|
description: Gitea token (ci-bot) for apps repo push and API operations
|
|
|
|
|
required: true
|
|
|
|
|
s3-access-key:
|
2026-08-29 21:22:04 +00:00
|
|
|
description: Garage access key id (required by the legacy single-surface contract)
|
|
|
|
|
required: false
|
2026-05-06 08:07:28 -05:00
|
|
|
s3-secret-key:
|
2026-08-29 21:22:04 +00:00
|
|
|
description: Garage secret access key (required by the legacy single-surface contract)
|
|
|
|
|
required: false
|
2026-05-06 08:07:28 -05:00
|
|
|
s3-endpoint:
|
2026-05-28 10:04:24 -05:00
|
|
|
# Targets garage-s3 (data-only Service) so requests do not round-robin onto
|
|
|
|
|
# the gateway pod, whose emptyDir-backed metadata view intermittently
|
|
|
|
|
# returns "No such key" through the S3 API.
|
2026-05-06 08:07:28 -05:00
|
|
|
description: Garage S3 endpoint URL
|
|
|
|
|
required: false
|
2026-05-28 10:04:24 -05:00
|
|
|
default: http://garage-s3.storage.svc:3900
|
2026-05-06 08:07:28 -05:00
|
|
|
garage-admin-token:
|
2026-08-29 21:22:04 +00:00
|
|
|
description: Garage admin API token (required only for legacy aliases — used to reconcile bucket globalAliases)
|
2026-05-06 08:07:28 -05:00
|
|
|
required: false
|
|
|
|
|
garage-admin-endpoint:
|
|
|
|
|
description: Garage admin API endpoint URL
|
|
|
|
|
required: false
|
|
|
|
|
default: http://garage.storage.svc:3903
|
|
|
|
|
username:
|
|
|
|
|
description: Gitea username for git operations
|
|
|
|
|
required: false
|
|
|
|
|
default: ci-bot
|
2026-09-06 00:53:35 +00:00
|
|
|
artifacts:
|
|
|
|
|
# Scopes building and publishing only. Routes, Ingresses and the immutable
|
|
|
|
|
# -path history are always rendered from the whole site.yaml, so a scoped
|
|
|
|
|
# run never retires another artifact's route.
|
|
|
|
|
description: Space- or comma-separated subset of site.yaml artifacts to build and publish (default is every declared artifact)
|
|
|
|
|
required: false
|
|
|
|
|
default: ''
|
2026-05-06 08:07:28 -05:00
|
|
|
runs:
|
|
|
|
|
using: composite
|
|
|
|
|
steps:
|
|
|
|
|
- name: Setup
|
|
|
|
|
shell: bash
|
|
|
|
|
run: python3 ${{ github.action_path }}/scripts/setup.py
|
|
|
|
|
|
|
|
|
|
- name: Build
|
|
|
|
|
shell: bash
|
|
|
|
|
run: python3 ${{ github.action_path }}/scripts/publish.py build
|
|
|
|
|
env:
|
|
|
|
|
SITE_REPO: ${{ github.repository }}
|
|
|
|
|
SITE_DIR: ${{ github.workspace }}
|
|
|
|
|
ACTION_DIR: ${{ github.action_path }}
|
|
|
|
|
GITHUB_RUN_NUMBER: ${{ github.run_number }}
|
|
|
|
|
CI_BOT_USER: ${{ inputs.username }}
|
2026-09-06 00:53:35 +00:00
|
|
|
SITE_ARTIFACTS: ${{ inputs.artifacts }}
|
2026-05-06 08:07:28 -05:00
|
|
|
|
|
|
|
|
- name: Deploy
|
|
|
|
|
shell: bash
|
|
|
|
|
run: python3 ${{ github.action_path }}/scripts/publish.py deploy
|
|
|
|
|
env:
|
|
|
|
|
SITE_REPO: ${{ github.repository }}
|
|
|
|
|
SITE_DIR: ${{ github.workspace }}
|
|
|
|
|
ACTION_DIR: ${{ github.action_path }}
|
|
|
|
|
CI_BOT_TOKEN: ${{ inputs.token }}
|
|
|
|
|
CI_BOT_USER: ${{ inputs.username }}
|
|
|
|
|
AWS_ACCESS_KEY_ID: ${{ inputs.s3-access-key }}
|
|
|
|
|
AWS_SECRET_ACCESS_KEY: ${{ inputs.s3-secret-key }}
|
|
|
|
|
AWS_DEFAULT_REGION: sjc001
|
|
|
|
|
GARAGE_S3_ENDPOINT: ${{ inputs.s3-endpoint }}
|
|
|
|
|
GARAGE_ADMIN_ENDPOINT: ${{ inputs.garage-admin-endpoint }}
|
|
|
|
|
GARAGE_ADMIN_TOKEN: ${{ inputs.garage-admin-token }}
|
|
|
|
|
GITHUB_RUN_NUMBER: ${{ github.run_number }}
|
2026-09-06 00:53:35 +00:00
|
|
|
SITE_ARTIFACTS: ${{ inputs.artifacts }}
|