Skip to content

Instantly share code, notes, and snippets.

@nbraud nbraud/.gitignore
Last active Apr 23, 2018

Embed
What would you like to do?
Test for the Ansible apt module
/.vagrant
/log
*.retry
[defaults]
inventory = ./.vagrant/provisioners/ansible/inventory
log_path = ./log
nocows=1
[ssh_connection]
ssh_args = -o UserKnownHostsFile=/dev/null -o IdentitiesOnly=yes -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no
---
- hosts: default
become: yes
tasks:
- name: Uninstall ZSH
apt:
name: zsh
state: absent
autoremove: yes
- name: Install the APT module for python
apt:
name:
- python-apt
- python3-apt
state: present
- hosts: default
become: yes
tasks:
- name: Install zsh-antigen
apt:
name: zsh-antigen
state: present
- name: Install zsh
apt:
name: zsh
state: present
- name: Uninstall zsh-antigen
apt:
name: zsh-antigen
state: absent
- name: apt autoremove
apt:
autoremove: yes
- name: Check that ZSH is installed
command: zsh -c true
Vagrant.configure("2") do |config|
config.vm.box = "debian/stretch64"
# Disable the new default behavior introduced in Vagrant 1.7, to
# ensure that all Vagrant machines will use the same SSH key pair.
# See https://github.com/mitchellh/vagrant/issues/5005
config.ssh.insert_key = false
config.vm.provision "ansible" do |ansible|
ansible.verbose = "v"
ansible.playbook = "provision.yml"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.