name: Self-Host Tests Smoke on: pull_request: branches: ['master'] paths: - 'docker/**/*' # Cancel old builds on new commit for same workflow + branch/PR concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} cancel-in-progress: true permissions: contents: read jobs: build: runs-on: blacksmith-4vcpu-ubuntu-2404 strategy: fail-fast: false matrix: config: [default, logs, envoy, rustfs, envoy-rustfs] steps: - uses: actions/checkout@v4 with: persist-credentials: false sparse-checkout: | docker/ - uses: actions/setup-node@v4 with: node-version: '22' - name: Generate keys shell: bash run: | set -euo pipefail cd docker cp .env.example .env sh utils/generate-keys.sh --update-env sh utils/add-new-auth-keys.sh --update-env - name: Start self-hosted Supabase shell: bash # Ensure all services can be started and healthy with default config run: | set -euo pipefail cd docker yq -i '.services.supavisor.environment.RLIMIT_NOFILE=1024' docker-compose.yml if [ "${{ matrix.config }}" = "logs" ]; then docker compose -f docker-compose.yml -f docker-compose.logs.yml up --quiet-pull --wait --wait-timeout 180 elif [ "${{ matrix.config }}" = "envoy" ]; then docker compose -f docker-compose.yml -f docker-compose.envoy.yml up --quiet-pull --wait --wait-timeout 180 elif [ "${{ matrix.config }}" = "rustfs" ]; then docker compose -f docker-compose.yml -f docker-compose.rustfs.yml up --quiet-pull --wait --wait-timeout 180 elif [ "${{ matrix.config }}" = "envoy-rustfs" ]; then docker compose -f docker-compose.yml -f docker-compose.envoy.yml -f docker-compose.rustfs.yml up --quiet-pull --wait --wait-timeout 180 else docker compose up --quiet-pull --wait --wait-timeout 180 fi - name: Run container log tests shell: bash run: | set -euo pipefail cd docker sh tests/test-container-logs.sh - name: Run smoke tests shell: bash run: | set -euo pipefail cd docker sh tests/test-self-hosted.sh - name: Run API keys and asymmetric auth tests shell: bash run: | set -euo pipefail cd docker sh tests/test-auth-keys.sh - name: Run S3 protocol tests shell: bash run: | set -euo pipefail cd docker sh tests/test-s3.sh