summarylogtreecommitdiffstats
path: root/tor.install
diff options
context:
space:
mode:
Diffstat (limited to 'tor.install')
-rw-r--r--tor.install19
1 files changed, 19 insertions, 0 deletions
diff --git a/tor.install b/tor.install
new file mode 100644
index 000000000000..02ad0185b79f
--- /dev/null
+++ b/tor.install
@@ -0,0 +1,19 @@
+post_install() {
+ echo "==> "
+ echo "==> Tor has been preconfigured to run as a client only"
+ echo "==> Tor is experimental software, Do not rely on it for strong anonymity."
+ echo "==> "
+ post_upgrade
+}
+
+post_upgrade() {
+ systemd-sysusers tor.conf
+ systemd-tmpfiles --create tor.conf
+ chown -R tor:tor /etc/tor
+ chmod -R 750 /etc/tor
+}
+
+pre_remove() {
+ getent passwd tor &>/dev/null && userdel tor &> /dev/null
+ getent group tor &>/dev/null && groupdel tor &> /dev/null
+}