From b3e320e064a5a2a071f6282577d886c33e0b1e7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Soko=C5=82owski?= Date: Thu, 26 Mar 2020 19:04:59 +0100 Subject: [PATCH] deploy 2GB swap files on Nimbus hosts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jakub SokoĊ‚owski --- ansible/group_vars/all.yml | 4 ++++ ansible/main.yml | 2 ++ ansible/requirements.yml | 4 ++++ 3 files changed, 10 insertions(+) diff --git a/ansible/group_vars/all.yml b/ansible/group_vars/all.yml index c87954c..8cd9d7e 100644 --- a/ansible/group_vars/all.yml +++ b/ansible/group_vars/all.yml @@ -30,6 +30,10 @@ bootstrap__extra_volume_path: '/docker' # Disable Watchtower cleanup to avoid removal errors bootstrap__watchtower_cleanup_flag: false +# Beacon nodes can be quite memory hungry +swap_file_path: '/docker/main.swap' +swap_file_size_mb: 2048 + # Custom SSH accounts for Nimbus fleet bootstrap__active_users: - { name: adamb, uid: 7003, groups: [] } diff --git a/ansible/main.yml b/ansible/main.yml index 16b14b9..b65cafa 100644 --- a/ansible/main.yml +++ b/ansible/main.yml @@ -19,6 +19,8 @@ - nimbus-master - nimbus-slaves tags: beacon-node + roles: + - { role: swap-file, tags: swap-file } tasks: - include_role: name: infra-role-beacon-node diff --git a/ansible/requirements.yml b/ansible/requirements.yml index 718e0e3..6497d93 100644 --- a/ansible/requirements.yml +++ b/ansible/requirements.yml @@ -57,3 +57,7 @@ - name: systemd-timer src: git@github.com:status-im/infra-role-systemd-timer.git scm: git + +- name: swap-file + src: git@github.com:status-im/infra-role-swap-file.git + scm: git