on: push
jobs:
  build:
    runs-on: docker
    container:
      image: forgejo.zenerdio.de/sebastian/c3space-website-ci:v0.2.0
    steps:
      - uses: actions/checkout@v3
      - uses: actions/cache@v3
        with:
          path: |
            virtenv
            cache
            output
          key: c3space-nikola-${{ github.ref_name }}
      - run: python3 -m venv virtenv
      - run: . virtenv/bin/activate; pip install -r requirements.txt
      - run: . virtenv/bin/activate; nikola build
