Run periodic-weekly jobs for master branch only #142
Workflow file for this run
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: Lint | |
on: | |
- push | |
- pull_request | |
jobs: | |
func: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Install dependencies | |
run: | | |
set -euxo pipefail | |
python -m pip install --upgrade pip | |
pip install tox | |
sudo snap install --classic juju --channel=2.9/stable | |
sudo lxd init --auto | |
# This is a throw-away CI environment, do not do this at home | |
sudo chmod 666 /var/snap/lxd/common/lxd/unix.socket | |
# until Juju provides stable IPv6-support we unfortunately need this | |
lxc network set lxdbr0 ipv6.address none | |
# iptables updates to allow traffic to/from LXD bridge/external network | |
sudo iptables -I DOCKER-USER -i lxdbr0 -o eth0 -j ACCEPT | |
sudo iptables -I DOCKER-USER -o lxdbr0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT | |
juju bootstrap localhost | |
- name: Bundle validation with tox using dry-run juju deploy | |
run: tox -e lint | |
- name: consider debugging | |
uses: lhotari/action-upterm@v1 | |
if: failure() |