From 42a8d71ebf327f3433d3c244468a32214d4eb3f7 Mon Sep 17 00:00:00 2001 From: Kevin Froman Date: Sun, 22 Mar 2020 21:54:20 -0500 Subject: [PATCH] added script to start Onionr in RAM --- start-ram.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 start-ram.sh diff --git a/start-ram.sh b/start-ram.sh new file mode 100755 index 00000000..41c4e4f8 --- /dev/null +++ b/start-ram.sh @@ -0,0 +1,16 @@ +#!/bin/sh +if [ -d "/dev/shm" ] +then + echo "Using /dev/shm to make a RAM based Onionr instance." +else + echo "This system does not have /dev/shm. Cannot use this script." + exit 9; +fi +ONIONR_HOME=/dev/shm/onionr$RANDOM$RANDOM$RANDOM +export ONIONR_HOME +echo "Onionr has been launched with a temporary home directory using /dev/shm. Note that the OS may still write to swap if applicable." +echo "Future Onionr commands will use your set or default Onionr home directory, unless you set it to $ONIONR_HOME" +echo "Ultimately, a live boot operating system such as Tails or Debian would be better for you to use." +$(dirname $0)/onionr.sh start & disown +sleep 2 +$(dirname $0)/onionr.sh open-home \ No newline at end of file