From 465e7ef243f85db27642b2cd626841e9e4be848e Mon Sep 17 00:00:00 2001 From: Michael Fritch Date: Wed, 12 May 2021 17:27:50 -0600 Subject: [PATCH] cephadm: add HAProxy sysctl settings Signed-off-by: Michael Fritch --- src/cephadm/cephadm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/cephadm/cephadm b/src/cephadm/cephadm index a9f3d9a6c32a..a0101b9b495b 100755 --- a/src/cephadm/cephadm +++ b/src/cephadm/cephadm @@ -746,6 +746,13 @@ class HAproxy(object): mounts[os.path.join(data_dir, 'haproxy')] = '/var/lib/haproxy' return mounts + @staticmethod + def get_sysctl_settings() -> List[str]: + return [ + '# IP forwarding', + 'net.ipv4.ip_forward = 1', + ] + ################################## @@ -2969,6 +2976,8 @@ def install_sysctl(ctx: CephadmContext, fsid: str, daemon_type: str) -> None: if daemon_type == 'osd': lines = OSD.get_sysctl_settings() + elif daemon_type == 'haproxy': + lines = HAproxy.get_sysctl_settings() elif daemon_type == 'keepalived': lines = Keepalived.get_sysctl_settings() -- 2.47.3