summaryrefslogtreecommitdiffstats
path: root/config/chroot_local-includes/usr/local/bin/generate-tor-browser-profile
diff options
context:
space:
mode:
Diffstat (limited to 'config/chroot_local-includes/usr/local/bin/generate-tor-browser-profile')
-rwxr-xr-xconfig/chroot_local-includes/usr/local/bin/generate-tor-browser-profile13
1 files changed, 13 insertions, 0 deletions
diff --git a/config/chroot_local-includes/usr/local/bin/generate-tor-browser-profile b/config/chroot_local-includes/usr/local/bin/generate-tor-browser-profile
new file mode 100755
index 0000000..bdb0e0c
--- /dev/null
+++ b/config/chroot_local-includes/usr/local/bin/generate-tor-browser-profile
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -eu
+
+USER_PROFILE="${HOME}/.tor-browser"
+
+if [ -e "${USER_PROFILE}" ]; then
+ echo "A tor-browser profile already exists at: ${USER_PROFILE}" >&2
+ exit 1
+fi
+
+mkdir -p "${USER_PROFILE}"
+cp -a /etc/tor-browser/profile "${USER_PROFILE}"/profile.default