This repository has been archived on 2023-05-31. You can view files and clone it, but cannot push or open issues or pull requests.
python-blog/.builds/freebsd.yml

37 lines
1 KiB
YAML

image: freebsd/12.x
packages:
- python39
- py39-sqlite3
- jpeg-turbo
- py37-ansible
sources:
- https://git.sr.ht/~crocmagnon/blog
secrets:
- ea931da1-9acd-47b0-b6c9-52b8b61c4647 # Ansible hosts file
- 5c948915-48c2-4542-8fc1-a5676f4d7126 # Deploy SSH key
environment:
POETRY_VERSION: 1.1.4
tasks:
- install_poetry: |
mkdir $HOME/bin
ln -s $(which python3.9) $HOME/bin/python
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python
echo "source $HOME/.poetry/env" >> ~/.buildenv
- install_deps: |
cd blog
poetry install -n
- test: |
cd blog
poetry run ./docker/runtests.sh
- check-branch: |
cd blog
if [ "$(git rev-parse master)" != "$(git rev-parse HEAD)" ]; then \
complete-build; \
fi
- deploy: |
ansible-playbook -i ~/ansiblehosts --ssh-common-args "-o StrictHostKeyChecking=no" blog/ansible/playbook.yml
triggers:
- action: email
condition: failure
to: Gabriel Augendre <gabriel@augendre.info>