From patchwork Sun Jul 8 17:57:38 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [v3,4/5] hood files: Move files from /www to /tmp and link there From: Adrian Schmutzler X-Patchwork-Id: 874 Message-Id: <1531072659-4217-4-git-send-email-freifunk@adrianschmutzler.de> To: franken-dev@freifunk.net Date: Sun, 8 Jul 2018 19:57:38 +0200 With this patch, changing the hood file happens in memory, so we do not have to write on flash "frequently". Signed-off-by: Adrian Schmutzler Reviewed-by: Robert Langhammer Reviewed-by: Fabian Bläse Tested-by: Fabian Bläse Reviewed-by: Tim Niemeyer --- Changes in v2: none Changes in v3: Remove references to sector file --- src/packages/fff/fff-hoodutils/files/lib/functions/fff/keyxchange | 2 +- src/packages/fff/fff-web/files/etc/uci-defaults/93-fff-uhttpd | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/packages/fff/fff-hoodutils/files/lib/functions/fff/keyxchange b/src/packages/fff/fff-hoodutils/files/lib/functions/fff/keyxchange index 40ebe4f..e601e0d 100644 --- a/src/packages/fff/fff-hoodutils/files/lib/functions/fff/keyxchange +++ b/src/packages/fff/fff-hoodutils/files/lib/functions/fff/keyxchange @@ -6,7 +6,7 @@ hoodfiletmp="/tmp/hoodfile" hoodfileref="/tmp/hoodfileref" -hoodfilewww="/www/hood/keyxchangev2data" +hoodfilewww="/tmp/hoodfilewww" getJsonPath() { jsonfile="" diff --git a/src/packages/fff/fff-web/files/etc/uci-defaults/93-fff-uhttpd b/src/packages/fff/fff-web/files/etc/uci-defaults/93-fff-uhttpd index 42376ad..248a78b 100644 --- a/src/packages/fff/fff-web/files/etc/uci-defaults/93-fff-uhttpd +++ b/src/packages/fff/fff-web/files/etc/uci-defaults/93-fff-uhttpd @@ -1,5 +1,9 @@ #!/bin/sh +. /lib/functions/fff/keyxchange + +ln -s "$hoodfilewww" /www/hood/keyxchangev2data + uci batch <