CI: use ghcr.io/macbre/nginx-http3:1.27.0 (#1390) #1481
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check if a Docker image can be built | |
on: | |
push: | |
branches: [ devel ] | |
pull_request: | |
jobs: | |
build_docker_image: | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
env: | |
DOCKER_TAG: ghcr.io/macbre/phantomas:latest | |
steps: | |
- uses: actions/checkout@v4 | |
# https://github.com/marketplace/actions/build-and-push-docker-images | |
- name: Build the Docker image with ${{ env.DOCKER_TAG }} tag | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
tags: ${{ env.DOCKER_TAG }} | |
build-args: | | |
GITHUB_SHA=${{ github.sha }} | |
cache-from: | | |
${{ env.DOCKER_TAG }} | |
- name: Inspect built image | |
run: | | |
docker images | |
docker inspect --format='{{json .Config.Labels}}' ${{ env.DOCKER_TAG }} | jq | |
- name: Run phantomas CLI script inside the container | |
run: | | |
./test/server-start.sh | |
docker run \ | |
--network=host \ | |
--security-opt seccomp=$(pwd)/chrome-seccomp.json \ | |
${{ env.DOCKER_TAG }} ./bin/phantomas.js http://127.0.0.1:8888/ --pretty |