I don't wanna spend a whole day setting up my development environment, get me my environment NOW!!
-
Install Ansible
-
Modify
hosts.yml
for the local or remote machine to be provisioned. -
$ ansible-playbook -i hosts.yml playbooks/playbook.yml
. Added-K
if you are running locally and wish Ansible to prompt forsudo
password. -
Have a cup of coffee and enjoy the environment ;)
env_user
: User-specific configurations will be installed to this user's home directory.env_has_x11
: Whether the system has X11 enabled. This could affect several configurations.env_has_wayland
: Whether the system has Wayland enabled. This could affect several configurations.python_versions
: Required Python versions to be installed bypyenv
. Default is2.7.15
and3.6.8
.
The user specified by env_user
must exist.
Ansible must have the ability to access the target system through SSH.
Both username/password and private key authentication work, but you have to change your hosts.yml
accordingly.
The target system must have Python installed (Python2 >= 2.6, Python3 >= 3.5).
If the path of the Python interpreter is different from /usr/bin/python
,
setting the variable ansible_python_interpreter
on hosts.yml
to the interpreter's path, e.g:
ansible_python_interpreter: /usr/bin/python3.6
The target system must have sudo
installed (For other options, see
here).
If the ansible_user
on the target system requires password to sudo
,
setting the variable ansible_become_pass
to the password.
The other way to workaround this is to make the user run sudo
without entering password.
Modify the sudoers file (using visudo
, etc.):
USERNAME ALL=(ALL) NOPASSWD:ALL