Files
computer-playbook/.github/workflows/test-deploy-server.yml
T

95 lines
2.1 KiB
YAML

name: Test Infinito.Nexus Deploy (server)
on:
workflow_call:
inputs:
distros:
description: "Space-separated distro list"
required: true
type: string
permissions:
contents: read
packages: read
env:
TEST_DEPLOY_TYPE: server
DISTROS: ${{ inputs.distros }}
ONLY_APP: ""
NIX_CONFIG: |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
INFINITO_IMAGE_TAG: ci-${{ github.sha }}
# required for mirrors generation inside container (no fallbacks)
GITHUB_REPOSITORY_OWNER: ${{ github.repository_owner }}
INFINITO_GHCR_MIRROR_PREFIX: mirror
jobs:
discover:
name: discover apps (arch)
runs-on: ubuntu-latest
timeout-minutes: 60
outputs:
apps: ${{ steps.discover.outputs.apps }}
steps:
- uses: actions/checkout@v6
- name: Install jq
shell: bash
run: |
set -euo pipefail
sudo apt-get update
sudo apt-get install -y jq
- name: Install deps (jq + envsubst)
shell: bash
run: |
set -euo pipefail
sudo apt-get update
sudo apt-get install -y jq gettext-base
- name: Start stack for discovery (arch)
shell: bash
run: |
set -euo pipefail
make docker-up
- name: Discover apps
id: discover
run: |
make ci-discover-output
server:
name: deploy:server (${{ matrix.app }})
runs-on: ubuntu-latest
timeout-minutes: 240
needs: discover
strategy:
fail-fast: false
matrix:
app: ${{ fromJson(needs.discover.outputs.apps) }}
steps:
- uses: actions/checkout@v6
- name: Install jq
shell: bash
run: |
set -euo pipefail
sudo apt-get update
sudo apt-get install -y jq
- name: Start stack (arch)
shell: bash
run: |
set -euo pipefail
make docker-up
- name: Deploy app
shell: bash
run: |
set -euo pipefail
export TEST_DEPLOY_TYPE="server"
export APP="${{ matrix.app }}"
make ci-deploy-app