From 874fa4d375aa139e1a442693654ac9f5abe158f9 Mon Sep 17 00:00:00 2001 From: Rafael dos Santos Silva Date: Tue, 27 Nov 2018 05:39:46 -0200 Subject: [PATCH] Make our swap config compatible with systemd >= 207 (#331) --- discourse-setup | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discourse-setup b/discourse-setup index 832fe70..c4f263b 100755 --- a/discourse-setup +++ b/discourse-setup @@ -144,7 +144,7 @@ check_disk_and_memory() { swapon /swapfile echo "/swapfile swap swap auto 0 0" | tee -a /etc/fstab sysctl -w vm.swappiness=10 - echo vm.swappiness = 10 | tee -a /etc/sysctl.conf + echo 'vm.swappiness = 10' > /etc/sysctl.d/30-discourse-swap.conf total_swap=`free -g --si | awk ' /Swap:/ {print $2} '` if [ "$total_swap" -lt 2 ]; then -- 2.25.1