Compare commits

..

9 commits

Author SHA1 Message Date
Víðir Valberg Guðmundsson 5d0c913c2a Add ssl_certs_enabled variable and use it to avoid ssl certs when running on vagrant 2022-11-15 23:05:52 +01:00
Sam A. 42ebebc3f5
Remove state: latest 2022-11-14 18:04:01 +01:00
Sam A. 79ec0627d4
Naming changes 2022-11-14 17:50:19 +01:00
Sam A. 3b7c096f8e
Simplify config and rename some files 2022-11-14 00:13:24 +01:00
Sam A. 01d9d3c04b
Don't use local config for Docker registry login
It doesn't work when deploying in Vagrant :(
2022-11-13 22:39:14 +01:00
Sam A. 41f09e7b33
Vagrant: Use same Ubuntu version as in production 2022-11-13 22:04:37 +01:00
Sam A. d0904a96a8
Fix SSH port logic again 2022-11-13 22:03:45 +01:00
Sam A. 581c832b36
Some Vagrant fixes
Only install Dell OpenManage if not running in a VM, and fix SSH port
logic.
2022-11-13 21:42:52 +01:00
Sam A. 6a16328b7b
Make Ansible setup testable in Vagrant
Added logic to change the sshd port if not already configured,
configued Vagrantfile to work properly and fixed a couple of deploy
errors.
2022-11-13 20:26:58 +01:00
2 changed files with 17 additions and 13 deletions

View file

@ -4,14 +4,14 @@ users:
comment: Jesper Hess Nielsen
password: '!'
groups: []
ssh_keys: []
keys: []
- name: valberg
comment: Vidir Valberg Gudmundsson
password: $6$qt3G.E.CxhC$OwBDn4rZUbCz06HLEMBHjgvKjxiv/eeerbklTHi.gpHIn1OejzX3k2.0NM0Dforaw6Yn5Y8Cgn8kL2FdbQLZ3/
groups:
- sudo
ssh_keys:
keys:
- ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDUmGeHc6QXDcJHkmVxbTUv04Q3vs20avquoGr6eOkkvYbcgjuFnBOOtvs2Nul1odcvvnHa1nN7DfL8XJamiwsB1B/xe2seaNS1axgwk9XowlVN9pgga8gsC+4gZWBtSObG2GR8n4NtPENzPmW5deNn8dRpTvULPMxZ0VRE9yNQOx8v8w85yYh+vxbbkWGVDYJU23yuJI50U9y6bXxNHinsACDFBeR/gi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VYrcoQNru5ETxL+37t reynir@spurv
@ -28,5 +28,7 @@ users:
password: $6$18dN367fG162hQ9A$Aqkf3O24Ve1btzh1PPOPg3uyydv/AQYUxethcoB4klotebJq3/XsydYT7XBuarxfDccVwyPTMlsP3U8VfQpG60
groups:
- sudo
ssh_keys:
keys:
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPd/4fQV7CL8/KVwbo/phiV5UdXFBIDlkZ+ps8C7FeRf samsapti
volume_root_folder: "/docker-volumes"

View file

@ -4,20 +4,22 @@
name: "{{ item.name }}"
comment: "{{ item.comment }}"
password: "{{ item.password }}"
groups: "{{ item.groups }}"
update_password: "always"
update_password: "on_create"
groups: "{{ item.groups }}"
loop: "{{ users | default([]) }}"
- name: "Add ssh authorized_keys"
authorized_key:
user: "{{ item.name }}"
key: "{{ item.ssh_keys | join('\n') }}"
exclusive: true
loop: "{{ users | default([]) }}"
user: "{{ item.0.name }}"
key: "{{ item.1 }}"
with_subelements:
- "{{ users | default([]) }}"
- keys
- name: "Add ssh authorized_keys to root user"
authorized_key:
user: "root"
key: "{{ item.ssh_keys | join('\n') }}"
exclusive: true
loop: "{{ users | default([]) }}"
key: "{{ item.1 }}"
with_subelements:
- "{{ users | default([]) }}"
- keys