Rebuild 1.15 #1298
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: Rebuild 1.15 | |
on: | |
schedule: | |
- cron: 30 2 * * * | |
jobs: | |
rebuild: | |
runs-on: ubuntu-22.04 | |
name: Rebuild 1.15 | |
timeout-minutes: 20 | |
strategy: | |
fail-fast: false | |
matrix: | |
branch: | |
- '1.15' | |
env: | |
REDIS_URL: redis://localhost:6379 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ matrix.branch }} | |
- uses: camptocamp/initialise-gopass-summon-action@v2 | |
with: | |
ci-gpg-private-key: ${{secrets.CI_GPG_PRIVATE_KEY}} | |
github-gopass-ci-token: ${{secrets.GOPASS_CI_GITHUB_TOKEN}} | |
patterns: pypi docker | |
if: github.repository == 'camptocamp/tilecloud-chain' | |
- run: echo "${HOME}/.local/bin" >> ${GITHUB_PATH} | |
- run: python3 -m pip install --user --requirement=ci/requirements.txt | |
- name: Checks | |
run: c2cciutils-checks | |
- run: touch tilecloud_chain/OpenLayers.js | |
- name: Build | |
run: | | |
python setup.py --long-description > PYPI.md | |
docker build --tag=camptocamp/tilecloud-chain:tests --target=tests . | |
docker build --tag=camptocamp/tilecloud-chain . | |
git --no-pager diff --check `git log --oneline | tail -1 | cut --fields=1 --delimiter=' '` | |
- name: Start | |
run: | | |
docker-compose up -d | |
# Wait for DB to be up | |
while ! docker-compose exec -T test psql -h db -p 5432 -U postgres -v ON_ERROR_STOP=1 -c "SELECT 1" -d tests | |
do | |
echo "Waiting for DB to be UP" | |
sleep 1 | |
done | |
timeout-minutes: 2 | |
- name: Test | |
run: | | |
docker-compose exec -T test pytest | |
docker-compose down | |
- run: docker-compose logs | |
if: failure() | |
- run: python3 -m pip install --requirement=requirements-publish.txt | |
- name: Publish | |
run: c2cciutils-publish --type=rebuild --branch=${{ matrix.branch }} |