6 |
6 |
7 # Interesting Variables |
7 # Interesting Variables |
8 |
8 |
9 ## `gui_enabled` |
9 ## `gui_enabled` |
10 |
10 |
11 Boolean. Install and configure GUI tools, or with vim, choose between `gtk` and |
11 Install and configure GUI tools, or with vim, choose between `gtk` and |
12 `nox`. |
12 `nox`. |
13 |
13 |
14 ## `disable_stock_users` |
14 ## `disable_stock_users` |
15 |
15 |
16 Boolean. Disable stock users like `pi` or `pine64`. |
16 Default `true`. Disable stock users like `pi` or `pine64`. |
|
17 |
|
18 ## `bootstrap_ansible_controller` |
|
19 |
|
20 Create an `ansible` user for the controller to connect as, with a public |
|
21 key set up and sudo permission. |
17 |
22 |
18 # Running |
23 # Running |
19 |
24 |
20 ## Push |
25 ## Push |
21 |
26 |
22 1. Create inventory file with target host, maybe extra vars |
27 1. Create inventory file with target hosts, maybe extra vars |
23 2. If we can ssh as root with key, use `-u root`. If we can sudo, use `-bK`. |
28 - For a single host, `-i ${hostname},` works directly. |
24 3. `ansible-playbook -i $inventory $args local.yml` |
29 2. We'll need to be root: |
|
30 1. If we can ssh as root with key, use `-u root`. |
|
31 2. If we can sudo, use `-bK`. |
|
32 3. `ansible-playbook -i $inventory $args playbook.yml` |
25 4. After the first run, `ansible` management user is created. |
33 4. After the first run, `ansible` management user is created. |
26 |
34 |
27 ## Pull |
35 ## Pull |
28 |
36 |
29 1. Install `ansible`, `git` |
37 1. Install `ansible`, `git` |
30 2. `echo -e '[localhost]\nlocalhost ansible_connection=local' >> /etc/ansible/hosts` |
38 2. `ansible-pull -i localhost, -c local -U https://github.com/merrilymeredith/devbox-ansible.git` |
31 3. `ansible-pull -U https://github.com/merrilymeredith/devbox-ansible.git` |
|
32 |
39 |
33 ### cloud-init |
40 ### cloud-init |
34 |
41 |
35 ```yaml |
42 ```yaml |
36 #cloud-config |
43 #cloud-config |
37 packages: |
44 packages: |
38 - ansible |
45 - ansible |
39 - git |
46 - git |
40 runcmd: |
47 runcmd: |
41 - echo '[localhost]\nlocalhost ansible_connection=local' >> /etc/ansible/hosts |
48 - ansible-pull -i localhost, -c local -U https://github.com/merrilymeredith/devbox-ansible.git |
42 - ansible-pull -U https://github.com/merrilymeredith/devbox-ansible.git |
|
43 ``` |
49 ``` |
44 |
50 |
45 # TODO |
51 # TODO |
46 |
52 |
47 - Make pull config install cron entry? |
53 - Make pull config or bootstrap install cron entry? |