Skip to content

Commit

Permalink
Add a global config option for Docker network MTU
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmehren committed Sep 11, 2024
1 parent b9a6426 commit b5ac236
Show file tree
Hide file tree
Showing 72 changed files with 145 additions and 0 deletions.
3 changes: 3 additions & 0 deletions group_vars/matrix_servers
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ matrix_playbook_docker_installation_daemon_options_auto:

matrix_playbook_docker_installation_daemon_options_custom: {}

# Default MTU for Docker networks
matrix_playbook_docker_network_mtu: 1500

# Controls whether to attach Traefik labels to services.
# This is separate from `devture_traefik_enabled`, because you may wish to disable Traefik installation by the playbook,
# yet still use Traefik installed in another way.
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-alertmanager-receiver/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_alertmanager_receiver_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-alertmanager-receiver.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_draupnir_for_all_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-draupnir-for-all.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-buscarron/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_buscarron_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-buscarron.service restarted, if necessary
ansible.builtin.service:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-chatgpt/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_chatgpt_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-chatgpt.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-draupnir/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_draupnir_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-draupnir.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-go-neb/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_go_neb_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-go-neb.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-honoroit/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_honoroit_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-honoroit.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_matrix_registration_bot_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-matrix-registration-bot.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_matrix_reminder_bot_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-matrix-reminder-bot.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-maubot/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_maubot_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-maubot.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-mjolnir/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_mjolnir_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-mjolnir.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bot-postmoogle/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_bot_postmoogle_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-bot-postmoogle.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_discord_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-discord.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_irc_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-irc.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_kakaotalk_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-kakaotalk-node.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_slack_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-slack support files installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_appservice_webhooks_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-appservice-webhooks support files installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_beeper_linkedin_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-beeper-linkedin.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_go_skype_bridge_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-go-skype-bridge.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_heisenbridge_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-heisenbridge.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bridge-hookshot/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_hookshot_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure mautrix-hookshot support files installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_discord_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-discord.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_facebook_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-facebook.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_gmessages_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-gmessages.service restarted, if necessary
ansible.builtin.service:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_googlechat_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-googlechat.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_hangouts_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-hangouts.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_instagram_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-instagram.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_meta_instagram_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure mautrix-meta-instagram.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_meta_messenger_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure mautrix-meta-messenger.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_signal_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-signal.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_slack_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-slack.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_telegram_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-telegram.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_twitter_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-twitter.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_whatsapp_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-whatsapp.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mautrix_wsproxy_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mautrix-wsproxy.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_discord_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-discord.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_groupme_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-groupme.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_instagram_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-instagram.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_slack_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-slack.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_steam_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-steam.service installed
ansible.builtin.template:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_twitter_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-mx-puppet-twitter.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bridge-sms/tasks/setup_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_sms_bridge_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-sms-bridge.service installed
ansible.builtin.template:
Expand Down
2 changes: 2 additions & 0 deletions roles/custom/matrix-bridge-wechat/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,8 @@
community.general.docker_network:
name: "{{ matrix_wechat_container_network }}"
driver: bridge
driver_options:
com.docker.network.driver.mtu: "{{ matrix_playbook_docker_network_mtu }}"

- name: Ensure matrix-wechat.service installed
ansible.builtin.template:
Expand Down
Loading

0 comments on commit b5ac236

Please sign in to comment.