mirror of
https://github.com/ChristianLempa/boilerplates.git
synced 2024-11-25 01:34:36 +01:00
fix: fix YAML indentation issues
This commit is contained in:
parent
6943bf8fef
commit
706ac210f7
@ -3,17 +3,17 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install fail2ban
|
- name: install fail2ban
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
name:
|
name:
|
||||||
- fail2ban
|
- fail2ban
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
- name: copy fail2ban configfiles
|
- name: copy fail2ban configfiles
|
||||||
ansible.builtin.copy:
|
ansible.builtin.copy:
|
||||||
src: configfiles/debian-sshd-default.conf
|
src: configfiles/debian-sshd-default.conf
|
||||||
dest: /etc/fail2ban/jail.d/debian-sshd-default.conf
|
dest: /etc/fail2ban/jail.d/debian-sshd-default.conf
|
||||||
- name: restart fail2ban
|
- name: restart fail2ban
|
||||||
ansible.builtin.systemd_service:
|
ansible.builtin.systemd_service:
|
||||||
state: restarted
|
state: restarted
|
||||||
daemon_reload: yes
|
daemon_reload: yes
|
||||||
name: fail2ban
|
name: fail2ban
|
||||||
|
@ -3,15 +3,15 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install public keys
|
- name: install public keys
|
||||||
ansible.posix.authorized_key:
|
ansible.posix.authorized_key:
|
||||||
user: "{{ lookup('env','USER') }}"
|
user: "{{ lookup('env','USER') }}"
|
||||||
state: present
|
state: present
|
||||||
key: "{{ lookup('file', '~/.ssh/id_rsa.pub') }}"
|
key: "{{ lookup('file', '~/.ssh/id_rsa.pub') }}"
|
||||||
- name: change sudoers file
|
- name: change sudoers file
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
path: /etc/sudoers
|
path: /etc/sudoers
|
||||||
state: present
|
state: present
|
||||||
regexp: '^%sudo'
|
regexp: '^%sudo'
|
||||||
line: '%sudo ALL=(ALL) NOPASSWD: ALL'
|
line: '%sudo ALL=(ALL) NOPASSWD: ALL'
|
||||||
validate: /usr/sbin/visudo -cf %s
|
validate: /usr/sbin/visudo -cf %s
|
||||||
|
@ -4,16 +4,16 @@
|
|||||||
become: yes
|
become: yes
|
||||||
become_user: "{{ lookup('env','USER') }}"
|
become_user: "{{ lookup('env','USER') }}"
|
||||||
tasks:
|
tasks:
|
||||||
- name: create new volume
|
- name: create new volume
|
||||||
community.docker.docker_volume:
|
community.docker.docker_volume:
|
||||||
name: portainer-data
|
name: portainer-data
|
||||||
- name: deploy portainer
|
- name: deploy portainer
|
||||||
community.docker.docker_container:
|
community.docker.docker_container:
|
||||||
name: portainer
|
name: portainer
|
||||||
image: "docker.io/portainer/portainer-ce"
|
image: "docker.io/portainer/portainer-ce"
|
||||||
ports:
|
ports:
|
||||||
- "9443:9443"
|
- "9443:9443"
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
- portainer-data:/data
|
- portainer-data:/data
|
||||||
restart_policy: unless-stopped
|
restart_policy: unless-stopped
|
||||||
|
@ -3,15 +3,15 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: deploy traefik
|
- name: deploy traefik
|
||||||
become_user: "{{ lookup('env','USER') }}"
|
become_user: "{{ lookup('env','USER') }}"
|
||||||
community.docker.docker_container:
|
community.docker.docker_container:
|
||||||
name: traefik
|
name: traefik
|
||||||
image: "traefik:v2.5"
|
image: "traefik:v2.5"
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "80:80"
|
||||||
- "443:443"
|
- "443:443"
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
- /etc/traefik:/etc/traefik
|
- /etc/traefik:/etc/traefik
|
||||||
restart_policy: unless-stopped
|
restart_policy: unless-stopped
|
||||||
|
@ -3,9 +3,9 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install core packages
|
- name: install core packages
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
name:
|
name:
|
||||||
- prometheus-node-exporter
|
- prometheus-node-exporter
|
||||||
- nfs-common
|
- nfs-common
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
|
@ -3,15 +3,15 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install packages
|
- name: install packages
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
name:
|
name:
|
||||||
- prometheus-node-exporter
|
- prometheus-node-exporter
|
||||||
- nfs-common
|
- nfs-common
|
||||||
- qemu-guest-agent
|
- qemu-guest-agent
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
- name: start guest qemu-guest-agent
|
- name: start guest qemu-guest-agent
|
||||||
ansible.builtin.service:
|
ansible.builtin.service:
|
||||||
name: qemu-guest-agent
|
name: qemu-guest-agent
|
||||||
state: started
|
state: started
|
||||||
enabled: yes
|
enabled: yes
|
||||||
|
@ -3,6 +3,6 @@
|
|||||||
hosts: "{{ my_hosts | d([]) }}"
|
hosts: "{{ my_hosts | d([]) }}"
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: reboot machine
|
- name: reboot machine
|
||||||
ansible.builtin.reboot:
|
ansible.builtin.reboot:
|
||||||
reboot_timeout: 3600
|
reboot_timeout: 3600
|
||||||
|
@ -2,10 +2,10 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install microk8s
|
- name: install microk8s
|
||||||
community.general.snap:
|
community.general.snap:
|
||||||
classic: yes
|
classic: yes
|
||||||
name: microk8s
|
name: microk8s
|
||||||
- name: add userpermissions
|
- name: add userpermissions
|
||||||
ansible.builtin.shell: "usermod -aG microk8s vagrant"
|
ansible.builtin.shell: "usermod -aG microk8s vagrant"
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
become: yes
|
become: yes
|
||||||
tasks:
|
tasks:
|
||||||
- name: install cockpit
|
- name: install cockpit
|
||||||
ansible.builtin.apt:
|
ansible.builtin.apt:
|
||||||
name: cockpit
|
name: cockpit
|
||||||
update_cache: yes
|
update_cache: yes
|
||||||
|
Loading…
Reference in New Issue
Block a user