diff --git a/docs/_Sidebar.md b/docs/_Sidebar.md index aa59208c8..5a5213a0b 100644 --- a/docs/_Sidebar.md +++ b/docs/_Sidebar.md @@ -76,7 +76,7 @@ - [SSHD](/roles/debian/ssh_server) - [SSL](/roles/debian/ssl) - [sudo config](/roles/debian/sudo_config) - - [General swap role to add swap space](/roles/debian/swap) + - [Swap](/roles/debian/swap) - [varnish-config](/roles/debian/varnish_config) - [wazuh](/roles/debian/wazuh) - [Init role](/roles/_init) diff --git a/docs/roles/debian/python_common.md b/docs/roles/debian/python_common.md index 2c9f384f9..94573f816 100644 --- a/docs/roles/debian/python_common.md +++ b/docs/roles/debian/python_common.md @@ -9,15 +9,17 @@ Packages required by all Python scripts and applications. ```yaml --- python_common: - remove_packages: - - python-pip - - python3-yaml # linters need a newer version of PyYAML than the one that ships with Debian - - python-botocore - - python-urllib3 + cleanup: false # set to true to remove unwanted packages + remove_packages: [] # list of packages to remove if cleanup: true + # Example from ansible role + #- python-pip + #- python3-yaml # linters need a newer version of PyYAML than the one that ships with Debian + #- python-botocore + #- python-urllib3 + # Commonly required Python system packages install_packages: - python3-distutils - python3-venv - - python3-pip - cloud-init # package can get removed with python3-yaml but we need it for auto-scale ``` diff --git a/docs/roles/debian/swap.md b/docs/roles/debian/swap.md index 8bfeaa59c..ef6f5f208 100644 --- a/docs/roles/debian/swap.md +++ b/docs/roles/debian/swap.md @@ -1,6 +1,5 @@ -# General swap role to add swap space - -By default, role is set to add 2G of swap space. +# Swap +General role to add swap space to servers. By default, role is set to add 4G of swap space. As a general rule of thumb, swap should be set to 2.5 times the amount of RAM. So if a server has 2G RAM, we should set swap to 5G by setting `size: "5G"` in the variables for that server. @@ -11,7 +10,7 @@ By default, role is set to add 2G of swap space. --- swap: count: 2048 - size: "2G" + size: "4G" swap_space: swapfile ``` diff --git a/roles/_meta/common_base/meta/main.yml b/roles/_meta/common_base/meta/main.yml index 140fcf1bb..9e3635fa6 100644 --- a/roles/_meta/common_base/meta/main.yml +++ b/roles/_meta/common_base/meta/main.yml @@ -45,7 +45,7 @@ dependencies: - role: debian/ansible ce_ansible: venv_path: "/home/{{ ce_provision.username }}/ansible" - venv_command: "/usr/bin/python3.11 -m venv" + venv_command: "/usr/bin/python3 -m venv" install_username: "{{ ce_provision.username }}" upgrade: enabled: true diff --git a/roles/debian/python_common/README.md b/roles/debian/python_common/README.md index 2c9f384f9..94573f816 100644 --- a/roles/debian/python_common/README.md +++ b/roles/debian/python_common/README.md @@ -9,15 +9,17 @@ Packages required by all Python scripts and applications. ```yaml --- python_common: - remove_packages: - - python-pip - - python3-yaml # linters need a newer version of PyYAML than the one that ships with Debian - - python-botocore - - python-urllib3 + cleanup: false # set to true to remove unwanted packages + remove_packages: [] # list of packages to remove if cleanup: true + # Example from ansible role + #- python-pip + #- python3-yaml # linters need a newer version of PyYAML than the one that ships with Debian + #- python-botocore + #- python-urllib3 + # Commonly required Python system packages install_packages: - python3-distutils - python3-venv - - python3-pip - cloud-init # package can get removed with python3-yaml but we need it for auto-scale ``` diff --git a/roles/debian/swap/README.md b/roles/debian/swap/README.md index ea66bc066..ef6f5f208 100644 --- a/roles/debian/swap/README.md +++ b/roles/debian/swap/README.md @@ -1,8 +1,5 @@ -# General swap role to add swap space - -By default, role is set to add 2G of swap space. -As a general rule of thumb, swap should be set to 2.5x of current RAM. -If server has 2G RAM, set RAM to 5G by creating swap.yml inside vars at local directory. +# Swap +General role to add swap space to servers. By default, role is set to add 4G of swap space. As a general rule of thumb, swap should be set to 2.5 times the amount of RAM. So if a server has 2G RAM, we should set swap to 5G by setting `size: "5G"` in the variables for that server.