mirror of
https://github.com/trailofbits/algo
synced 2024-11-18 09:25:38 +00:00
e8947f318b
* Refactoring, booleans declaration and update users fix * Make server_name more FQDN compatible * Rename variables * Define the default value for store_cakey * Skip a prompt about the SSH user if deploying to localhost * Disable reboot for non-cloud deployments * Enable EC2 volume encryption by default * Add default server value (localhost) for the local installation Delete empty files * Add default region to aws_region_facts * Update docs * EC2 credentials fix * Warnings fix * Update deploy-from-ansible.md * Fix a typo * Remove lightsail from the docs * Disable EC2 encryption by default * rename droplet to server * Disable dependencies * Disable tls_cipher_suite * Convert wifi-exclude to a string. Update-users fix * SSH access congrats fix * 16.04 > 18.04 * Dont ask for the credentials if specified in the environment vars * GCE server name fix
76 lines
2.0 KiB
YAML
76 lines
2.0 KiB
YAML
---
|
|
language: python
|
|
python: "2.7"
|
|
sudo: required
|
|
dist: trusty
|
|
|
|
services:
|
|
- docker
|
|
|
|
matrix:
|
|
fast_finish: true
|
|
|
|
addons:
|
|
apt:
|
|
sources:
|
|
- sourceline: 'ppa:ubuntu-lxc/stable'
|
|
- sourceline: 'ppa:wireguard/wireguard'
|
|
packages:
|
|
- python-pip
|
|
- lxd
|
|
- expect-dev
|
|
- debootstrap
|
|
- shellcheck
|
|
- tree
|
|
- bridge-utils
|
|
- dnsutils
|
|
- build-essential
|
|
- libssl-dev
|
|
- libffi-dev
|
|
- python-dev
|
|
- linux-headers-$(uname -r)
|
|
- wireguard-dkms
|
|
|
|
cache:
|
|
directories:
|
|
- $HOME/lxc/
|
|
pip: true
|
|
|
|
before_cache:
|
|
- mkdir $HOME/lxc
|
|
- sudo tar cf $HOME/lxc/cache.tar /var/lib/lxd/images/
|
|
- sudo chown $USER. $HOME/lxc/cache.tar
|
|
|
|
env:
|
|
- LXC_NAME=docker LXC_DISTRO=ubuntu LXC_RELEASE=18.04
|
|
|
|
before_install:
|
|
- test "${LXC_NAME}" != "docker" && sudo modprobe wireguard || docker build -t travis/algo .
|
|
|
|
install:
|
|
- sudo tar xf $HOME/lxc/cache.tar -C / || echo "Didn't extract cache."
|
|
- ssh-keygen -f ~/.ssh/id_rsa -t rsa -N ''
|
|
- chmod 0644 ~/.ssh/config
|
|
- echo -e "#cloud-config\nssh_authorized_keys:\n - $(cat ~/.ssh/id_rsa.pub)" | sudo lxc profile set default user.user-data -
|
|
- sudo cp -f tests/lxd-bridge /etc/default/lxd-bridge
|
|
- sudo service lxd restart
|
|
- sudo lxc launch ${LXC_DISTRO}:${LXC_RELEASE} ${LXC_NAME}
|
|
- until host ${LXC_NAME}.lxd 10.0.8.1 -t A; do sleep 3; done
|
|
- export LXC_IP="$(dig ${LXC_NAME}.lxd @10.0.8.1 +short)"
|
|
- pip install -r requirements.txt
|
|
- pip install ansible-lint
|
|
- gem install awesome_bot
|
|
- ansible-playbook --version
|
|
- tree . -L 2
|
|
|
|
script:
|
|
# - awesome_bot --allow-dupe --skip-save-results *.md docs/*.md --white-list paypal.com,do.co,microsoft.com,https://github.com/trailofbits/algo/archive/master.zip,https://github.com/trailofbits/algo/issues/new
|
|
# - shellcheck algo
|
|
# - ansible-lint main.yml users.yml deploy_client.yml
|
|
- ansible-playbook main.yml --syntax-check
|
|
- ./tests/local-deploy.sh
|
|
- ./tests/update-users.sh
|
|
|
|
notifications:
|
|
email: false
|