browsertrix/.github/workflows/ci.yaml
Ilya Kreymer 418c07bf0d
Local swarm + podman support (#261)
* backend: refactor swarm support to also support podman (#260)
- implement podman support as subclass of swarm deployment
- podman is used when 'RUNTIME=podman' env var is set
- podman socket is mapped instead of docker socket
- podman-compose is used instead of docker-compose (though docker-compose works with podman, it does not support secrets, but podman-compose does)
- separate cli utils into SwarmRunner and PodmanRunner which extends it
- using config.yaml and config.env, both copied from sample versions
- work on simplifying config: add docker-compose.podman.yml and docker-compose.swarm.yml and signing and debug configs in ./configs
- add {build,run,stop}-{swarm,podman}.sh in scripts dir
- add init-configs, only copy if configs don't exist
- build local image use current version of podman, to support both podman 3.x and 4.x
- additional fixes for after testing podman on centos
- docs: update Deployment.md to cover swarm, podman, k8s deployment
2022-06-14 00:13:49 -07:00

67 lines
1.5 KiB
YAML

name: Browsertrix Cloud Integration Test (for Swarm)
on: [push, pull_request]
jobs:
btrix-swarm-test:
runs-on: ubuntu-20.04
services:
registry:
image: registry:2
ports:
- 5000:5000
steps:
-
name: Checkout
uses: actions/checkout@v3
-
name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
with:
driver-opts: network=host
-
name: Copy Configs
run: ./scripts/init-configs.sh
-
name: Build Backend
uses: docker/build-push-action@v3
with:
context: backend
push: true
tags: localhost:5000/webrecorder/browsertrix-backend:latest
cache-from: type=gha,scope=backend
cache-to: type=gha,scope=backend,mode=max
-
name: Build Frontend
uses: docker/build-push-action@v3
with:
context: frontend
push: true
tags: localhost:5000/webrecorder/browsertrix-frontend:latest
cache-from: type=gha,scope=frontend
cache-to: type=gha,scope=frontend,mode=max
-
name: Run Bootstrap Script
run: ./test/setup.sh
-
name: Install Python
uses: actions/setup-python@v3
with:
python-version: '3.9'
-
name: Install Python Libs
run: pip install pytest requests
-
name: Backend Tests
run: py.test -vv ./backend/test/*.py