diff --git a/host_vars/github_ci/vars.yml b/host_vars/github_ci/vars.yml index 79847ef6..b64ddbad 100644 --- a/host_vars/github_ci/vars.yml +++ b/host_vars/github_ci/vars.yml @@ -8,6 +8,10 @@ system_timezone: "Europe/Amsterdam" system_user_uid: "4242" system_user_gid: "4242" +################################# +# docker # +################################# + docker_bridge_network_settings: network: "docker-network-main" puid: "{{ system_user_uid }}" @@ -58,7 +62,7 @@ duplicati_docker_settings: "{{ docker_bridge_network_settings }}" duplicati_port: 3009 filebrowser_docker_settings: "{{ docker_bridge_network_settings }}" -storage_filebrowser_port: 3010 +filebrowser_port: 3010 glances_docker_settings: "{{ docker_host_network_settings }}" glances_webui_port: 61208 diff --git a/host_vars/pi/vars.yml b/host_vars/pi/vars.yml deleted file mode 100644 index c38d6860..00000000 --- a/host_vars/pi/vars.yml +++ /dev/null @@ -1,92 +0,0 @@ ---- -smarthome_zigbee_coordinator: "/dev/ttyUSB0" - -docker_bridge_network_settings: - network: "docker-network-main" - puid: "{{ system_user_uid }}" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" - -docker_host_network_settings: - network: "host" - puid: "host" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" - -docker_autoupdate_enabled: true - -docker_autobackup_containers: - - name: "adguardhome" - volumes: - - "/opt/adguardhome/work" - - "/opt/adguardhome/conf" - - - name: "duplicati" - volumes: - - "/config" - - - name: "paperlessngx" - volumes: - - "/usr/src/paperless/data" - - "/usr/src/paperless/media" - - - name: "homebox" - volumes: - - "/data" - - - name: "homarr" - volumes: - - "/data" - - "/app/data/configs" - - - name: "immich-db" - volumes: - - "/var/lib/postgresql/data" - - - name: "jellyfin" - volumes: - - "/config" - - - name: "jellyseerr" - volumes: - - "/app/config" - - - name: "prowlarr" - volumes: - - "/config" - - - name: "radarr" - volumes: - - "/config" - - - name: "sonarr" - volumes: - - "/config" - - - name: "transmission" - volumes: - - "/config" - - - name: "filebrowser" - volumes: - - "/database.db" - - - name: "vaultwarden" - volumes: - - "/data" - - - name: "home-assistant" - volumes: - - "/config" - - - name: "zigbee2mqtt" - volumes: - - "/app/data" - - - name: "changedetection" - volumes: - - "/datastore" - - - name: "wallos" - volumes: - - "/var/www/html/db" diff --git a/host_vars/vps/vars.yml b/host_vars/vps/vars.yml deleted file mode 100644 index 42aa0bd9..00000000 --- a/host_vars/vps/vars.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -docker_bridge_network_settings: - network: "docker-network-main" - puid: "{{ system_user_uid }}" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" - -docker_host_network_settings: - network: "host" - puid: "host" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" - -docker_autoupdate_enabled: true diff --git a/playbook-github-ci.yml b/playbook-github-ci.yml index b1f408e1..45185cc8 100755 --- a/playbook-github-ci.yml +++ b/playbook-github-ci.yml @@ -12,7 +12,7 @@ tags: - "zsh" - - role: "docker" + - role: "artyorsh.selfhosted.docker" tags: - "docker" diff --git a/playbook-pi.yml b/playbook-pi.yml index fc7082d3..ad439697 100755 --- a/playbook-pi.yml +++ b/playbook-pi.yml @@ -16,15 +16,13 @@ tags: - "security" - - role: "docker" + - role: "artyorsh.selfhosted.docker" tags: - "docker" - role: "artyorsh.selfhosted.adguardhome" tags: - "adguardhome" - vars: - adguardhome_docker_settings: "{{ docker_host_network_settings }}" - role: "wireguard" vars: @@ -37,39 +35,10 @@ - "storage" - role: "artyorsh.yams.yams" - vars: - yams_user: - name: "{{ system_user_name }}" - password: "{{ system_user_password }}" - - yams_dir: - documents: "{{ storage_smb_share_local_dir }}/Documents" - downloads: "{{ storage_smb_share_local_dir }}/Downloads" - photos: "{{ storage_smb_share_local_dir }}/Photos" - movies: "{{ storage_smb_share_local_dir }}/Movies" - tvshows: "{{ storage_smb_share_local_dir }}/TV" - - yams_docker_settings: - network: "media" - puid: "{{ system_user_uid }}" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" tags: - "media" - role: "artyorsh.smarthome.smarthome" - vars: - # smarthome_zigbee_coordinator: "/dev/ttyUSB0" - - smarthome_user: - name: "{{ system_user_name }}" - password: "{{ system_user_password }}" - - smarthome_docker_settings: - network: "home" - puid: "{{ system_user_uid }}" - pgid: "{{ system_user_gid }}" - tz: "{{ system_timezone }}" tags: - "smarthome" @@ -78,38 +47,22 @@ - "monitoring" - role: "artyorsh.selfhosted.rss" - vars: - rss_docker_settings: "{{ docker_bridge_network_settings }}" - rss_miniflux_admin_user: - name: "{{ system_user_name }}" - password: "{{ system_user_password }}" - rss_rssbridge_bridges: ["Soundcloud", "Mixcloud", "Filter"] tags: - "rss" - role: "artyorsh.selfhosted.homebox" - vars: - homebox_docker_settings: "{{ docker_bridge_network_settings }}" tags: - "homebox" - role: "artyorsh.selfhosted.vaultwarden" - vars: - vaultwarden_docker_settings: "{{ docker_bridge_network_settings }}" tags: - "vaultwarden" - role: "artyorsh.selfhosted.duplicati" - vars: - duplicati_source_dir: "{{ storage_smb_share_local_dir }}" - duplicati_backups_dir: "{{ storage_smb_share_local_dir }}/backups" - duplicati_docker_settings: "{{ docker_bridge_network_settings }}" tags: - "duplicati" - role: "artyorsh.selfhosted.wallos" - vars: - wallos_docker_settings: "{{ docker_bridge_network_settings }}" tags: - "wallos" diff --git a/playbook-vps.yml b/playbook-vps.yml index 9540e2cb..0373c48a 100755 --- a/playbook-vps.yml +++ b/playbook-vps.yml @@ -16,7 +16,7 @@ tags: - "security" - - role: "docker" + - role: "artyorsh.selfhosted.docker" tags: - "docker" diff --git a/roles/docker/defaults/main.yml b/roles/docker/defaults/main.yml deleted file mode 100644 index ce18c7f4..00000000 --- a/roles/docker/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -docker_network_name: "docker-network-main" diff --git a/roles/docker/tasks/main.yml b/roles/docker/tasks/main.yml deleted file mode 100755 index 6ad74c80..00000000 --- a/roles/docker/tasks/main.yml +++ /dev/null @@ -1,21 +0,0 @@ ---- -- name: "Install and configure Docker" - ansible.builtin.include_role: - name: "artyorsh.selfhosted.docker" - vars: - docker_autobackup_enabled: true - docker_autobackup_dest_dir: "{{ storage_smb_share_local_dir }}/backups/docker-volumes" - docker_autobackup_schedule: { weekday: "*", hour: 2 } - # docker_autobackup_containers: [] - - docker_autoprune_enabled: true - docker_autoprune_schedule: { weekday: "*", hour: 1, minute: 30 } - docker_autoprune_until_hours: 168 - - # docker_autoupdate_enabled: true - docker_autoupdate_ignore_list: - - "cloudflare" - - "wireguard" - - "homeassistant" - - "miniflux-db" - docker_autoupdate_watchtower_docker_settings: "{{ docker_bridge_network_settings }}" diff --git a/roles/monitoring/tasks/main.yml b/roles/monitoring/tasks/main.yml index d81eb535..51962409 100644 --- a/roles/monitoring/tasks/main.yml +++ b/roles/monitoring/tasks/main.yml @@ -10,10 +10,3 @@ - name: "Install and configure Glances" ansible.builtin.include_role: name: "artyorsh.selfhosted.glances" - vars: - glances_notifier: "/etc/glances-notify.sh" - glances_fs_volumes: - - "{{ storage_smb_share_local_dir }}" - glances_docker_settings: "{{ docker_host_network_settings }}" - tags: - - "glances" diff --git a/roles/security/defaults/main.yml b/roles/security/defaults/main.yml index c6030801..d49a78d8 100644 --- a/roles/security/defaults/main.yml +++ b/roles/security/defaults/main.yml @@ -12,28 +12,3 @@ security_firewall_allow_rules: - desc: "Allow SSH" proto: "tcp" port: "{{ security_ssh_port }}" - - # https://www.home-assistant.io/integrations/homekit/#firewall - - desc: "Allow mDNS (for HomeKit)" - proto: "udp" - port: "5353" - - - desc: "Allow WireGuard" - proto: "udp" - port: "{{ wgeasy_udp_port }}" - - - desc: "Allow Glances" - proto: "tcp" - port: "{{ glances_webui_port }}" - - - desc: "Allow AdGuardHome (DNS)" - proto: "tcp" - port: "{{ adguardhome_dns_port }}" - - - desc: "Allow AdGuardHome (DNS)" - proto: "udp" - port: "{{ adguardhome_dns_port }}" - - - desc: "Allow AdGuardHome (Web UI)" - proto: "tcp" - port: "{{ adguardhome_webui_port }}" diff --git a/roles/storage/tasks/main.yml b/roles/storage/tasks/main.yml index 30de6faa..14078f5e 100644 --- a/roles/storage/tasks/main.yml +++ b/roles/storage/tasks/main.yml @@ -6,7 +6,3 @@ - name: "Install Filebrowser" ansible.builtin.include_role: name: "artyorsh.selfhosted.filebrowser" - vars: - filebrowser_port: "{{ storage_filebrowser_port }}" - filebrowser_storage_root_dir: "{{ storage_smb_share_local_dir }}" - filebrowser_docker_settings: "{{ docker_bridge_network_settings }}"