Skip to content
Snippets Groups Projects
Commit 325166f0 authored by nimrod's avatar nimrod
Browse files

Merge branch 'master' of /home/nimrod/Documents/Shore/Ansible/example

# Conflicts:
#	.travis.yml
#	molecule.yml
#	tasks/main.yml
parents f936dae0 c508b943
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
- id: flake8 - id: flake8
- id: check-symlinks - id: check-symlinks
- repo: https://github.com/adarnimrod/ansible-pre-commit.git - repo: https://github.com/adarnimrod/ansible-pre-commit.git
sha: 0fadd691465b97db8992cfc66650f630e433324b sha: v0.5.0
hooks: hooks:
- id: ansible-syntax-check - id: ansible-syntax-check
always_run: true always_run: true
......
...@@ -4,18 +4,21 @@ python: ["2.7", "3.5"] ...@@ -4,18 +4,21 @@ python: ["2.7", "3.5"]
dist: trusty dist: trusty
sudo: True sudo: True
group: beta group: beta
services: [docker]
env: env:
- platform: openbsd60 - platform: openbsd60
driver: vagrant - &openbsd59 platform=openbsd59
- &openbsd59 platform=openbsd59 driver=vagrant - platform: xenial
- driver: docker - platform: trusty
platform: all - platform: precise
- &stretch platform=stretch
- platform: jessie
- platform: wheezy
matrix: matrix:
fast_finish: True fast_finish: True
allow_failures: allow_failures:
- python: "3.5" - python: "3.5"
- env: *openbsd59 - env: *openbsd59
- env: *stretch
cache: cache:
- pip - pip
- directories: - directories:
...@@ -32,7 +35,7 @@ install: ...@@ -32,7 +35,7 @@ install:
script: script:
- pre-commit run --all-files - pre-commit run --all-files
- molecule test --driver $driver --platform $platform - molecule test --platform $platform
notifications: notifications:
webhooks: https://galaxy.ansible.com/api/v1/notifications/ webhooks: https://galaxy.ansible.com/api/v1/notifications/
......
...@@ -30,9 +30,8 @@ See :code:`tests/playbook.yml`. ...@@ -30,9 +30,8 @@ See :code:`tests/playbook.yml`.
Testing Testing
------- -------
Testing requires Python 2.7 and either Docker or Vagrant and Virtualbox. Testing requires Python 2.7, Vagrant and Virtualbox. Install the Python
Install the Python dependencies, dependent roles and roles required for dependencies, dependent roles and roles required for testing:
testing:
.. code:: shell .. code:: shell
......
...@@ -26,6 +26,8 @@ vagrant: ...@@ -26,6 +26,8 @@ vagrant:
box: ubuntu/trusty32 box: ubuntu/trusty32
- name: precise - name: precise
box: hashicorp/precise32 box: hashicorp/precise32
- name: stretch
box: remram/debian-9-i386
- name: jessie - name: jessie
box: deb/jessie-i386 box: deb/jessie-i386
- name: wheezy - name: wheezy
...@@ -43,48 +45,3 @@ vagrant: ...@@ -43,48 +45,3 @@ vagrant:
vm.provider "virtualbox" do |v| vm.provider "virtualbox" do |v|
v.customize "pre-boot", ["modifyvm", :id, "--hwvirtex", "off"] v.customize "pre-boot", ["modifyvm", :id, "--hwvirtex", "off"]
end end
docker:
containers:
- name: gitreceive-xenial
image: ubuntu
image_version: xenial
command: /sbin/init
privileged: True
volume_mounts:
- /sys/fs/cgroup:/sys/fs/cgroup
- /var/run/dbus/system_bus_socket:/var/run/dbus/system_bus_socket
environment:
DEBIAN_FRONTEND: noninteractive
container: docker
- name: gitreceive-trusty
image: ubuntu-upstart
image_version: trusty
command: /sbin/init
environment:
DEBIAN_FRONTEND: noninteractive
container: docker
- name: gitreceive-precise
image: ubuntu
image_version: precise
environment:
DEBIAN_FRONTEND: noninteractive
container: docker
- name: gitreceive-jessie
image: debian
image_version: jessie
command: /sbin/init
cap_add:
- SYS_ADMIN
volume_mounts:
- /sys/fs/cgroup:/sys/fs/cgroup
- /var/run/dbus/system_bus_socket:/var/run/dbus/system_bus_socket
environment:
DEBIAN_FRONTEND: noninteractive
container: docker
- name: gitreceive-wheezy
image: debian
image_version: wheezy
environment:
DEBIAN_FRONTEND: noninteractive
container: docker
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
- name: Assertions - name: Assertions
assert: assert:
that: that:
- ansible_os_family in ['Debian', 'OpenBSD'] - ansible_os_family in ['OpenBSD', 'Debian']
- gitreceive_public_keys is iterable - gitreceive_public_keys is iterable
- name: APT install prequisites - name: APT install prequisites
......
...@@ -5,7 +5,6 @@ ansible-lint==3.4.10 ...@@ -5,7 +5,6 @@ ansible-lint==3.4.10
pre-commit==0.11.0 pre-commit==0.11.0
piprot==0.9.7 piprot==0.9.7
python-vagrant==0.5.14 python-vagrant==0.5.14
docker-py==1.10.6
netaddr==0.7.19 netaddr==0.7.19
passlib==1.7.0 passlib==1.7.0
bcrypt==3.1.2 bcrypt==3.1.2
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment