Users and groups
This commit is contained in:
parent
cd54f26f84
commit
822fd47d32
|
@ -371,6 +371,8 @@ function remove_gogs {
|
||||||
remove_completion_param "install_gogs"
|
remove_completion_param "install_gogs"
|
||||||
sed -i '/gogs /d' $COMPLETION_FILE
|
sed -i '/gogs /d' $COMPLETION_FILE
|
||||||
remove_backup_database_local gogs
|
remove_backup_database_local gogs
|
||||||
|
deluser --remove-all-files gogs
|
||||||
|
delgroup gogs
|
||||||
|
|
||||||
function_check remove_ddns_domain
|
function_check remove_ddns_domain
|
||||||
remove_ddns_domain $GIT_DOMAIN_NAME
|
remove_ddns_domain $GIT_DOMAIN_NAME
|
||||||
|
@ -382,6 +384,7 @@ function install_gogs {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
adduser --disabled-login --gecos 'Gogs' $GOGS_USERNAME
|
adduser --disabled-login --gecos 'Gogs' $GOGS_USERNAME
|
||||||
|
groupadd gogs
|
||||||
|
|
||||||
gogs_parameters
|
gogs_parameters
|
||||||
|
|
||||||
|
|
|
@ -483,7 +483,7 @@ function remove_matrix {
|
||||||
pip uninstall .
|
pip uninstall .
|
||||||
rm -rf $MATRIX_DATA_DIR
|
rm -rf $MATRIX_DATA_DIR
|
||||||
rm -rf /etc/matrix
|
rm -rf /etc/matrix
|
||||||
deluser matrix
|
deluser --remove-all-files matrix
|
||||||
delgroup matrix
|
delgroup matrix
|
||||||
remove_onion_service matrix ${MATRIX_ONION_PORT}
|
remove_onion_service matrix ${MATRIX_ONION_PORT}
|
||||||
remove_onion_service matrix ${MATRIX_FEDERATION_ONION_PORT}
|
remove_onion_service matrix ${MATRIX_FEDERATION_ONION_PORT}
|
||||||
|
|
|
@ -251,7 +251,7 @@ function remove_mediagoblin {
|
||||||
sed -i '/mediagoblin/d' $COMPLETION_FILE
|
sed -i '/mediagoblin/d' $COMPLETION_FILE
|
||||||
|
|
||||||
remove_nodejs mediagoblin
|
remove_nodejs mediagoblin
|
||||||
deluser mediagoblin
|
deluser --remove-all-files mediagoblin
|
||||||
delgroup mediagoblin
|
delgroup mediagoblin
|
||||||
|
|
||||||
function_check remove_ddns_domain
|
function_check remove_ddns_domain
|
||||||
|
|
|
@ -282,7 +282,8 @@ function remove_radicale {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
firewall_remove ${RADICALE_PORT} tcp
|
firewall_remove ${RADICALE_PORT} tcp
|
||||||
deluser radicale
|
deluser --remove-all-files radicale
|
||||||
|
delgroup radicale
|
||||||
|
|
||||||
function_check remove_onion_service
|
function_check remove_onion_service
|
||||||
remove_onion_service radicale ${RADICALE_ONION_PORT}
|
remove_onion_service radicale ${RADICALE_ONION_PORT}
|
||||||
|
@ -323,6 +324,7 @@ function install_radicale {
|
||||||
|
|
||||||
useradd -c "Radicale system account" -d /var/www/radicale -m -r -g radicale radicale
|
useradd -c "Radicale system account" -d /var/www/radicale -m -r -g radicale radicale
|
||||||
usermod -a -G www-data radicale
|
usermod -a -G www-data radicale
|
||||||
|
groupadd radicale
|
||||||
|
|
||||||
# create directories
|
# create directories
|
||||||
if [ ! -d /var/log/radicale ]; then
|
if [ ! -d /var/log/radicale ]; then
|
||||||
|
|
|
@ -372,7 +372,8 @@ function remove_tahoelafs {
|
||||||
remove_onion_service tahoelafs ${TAHOELAFS_ONION_PORT}
|
remove_onion_service tahoelafs ${TAHOELAFS_ONION_PORT}
|
||||||
remove_onion_service storage-tahoelafs ${TAHOELAFS_STORAGE_ONION_PORT} $(get_tahoelafs_nick)
|
remove_onion_service storage-tahoelafs ${TAHOELAFS_STORAGE_ONION_PORT} $(get_tahoelafs_nick)
|
||||||
sed -i '/HidServAuth /d' /etc/tor/torrc
|
sed -i '/HidServAuth /d' /etc/tor/torrc
|
||||||
deluser tahoelafs
|
deluser --remove-all-files tahoelafs
|
||||||
|
delgroup tahoelafs
|
||||||
if [ -d $TAHOE_DIR ]; then
|
if [ -d $TAHOE_DIR ]; then
|
||||||
rm -rf $TAHOE_DIR
|
rm -rf $TAHOE_DIR
|
||||||
fi
|
fi
|
||||||
|
@ -616,16 +617,17 @@ function install_tahoelafs {
|
||||||
|
|
||||||
apt-get -yq install build-essential python-pip python-dev libffi-dev libssl-dev
|
apt-get -yq install build-essential python-pip python-dev libffi-dev libssl-dev
|
||||||
apt-get -yq install libcrypto++-dev python-pycryptopp python-cffi python-virtualenv
|
apt-get -yq install libcrypto++-dev python-pycryptopp python-cffi python-virtualenv
|
||||||
apt-get -yq install tahoe-lafs
|
|
||||||
pip install tahoe-lafs[tor]
|
|
||||||
|
|
||||||
# create a user
|
# create a user
|
||||||
if [ ! -d $TAHOE_DIR ]; then
|
if [ ! -d $TAHOE_DIR ]; then
|
||||||
# add a gogs user account
|
# add a gogs user account
|
||||||
adduser --disabled-login --gecos 'tahoe-lafs' tahoelafs
|
adduser --disabled-login --gecos 'tahoe-lafs' tahoelafs
|
||||||
adduser tahoelafs debian-tor
|
adduser tahoelafs debian-tor
|
||||||
|
groupadd tahoelafs
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
apt-get -yq install tahoe-lafs
|
||||||
|
pip install tahoe-lafs[tor]
|
||||||
|
|
||||||
if [ -d $TAHOE_DIR/Maildir ]; then
|
if [ -d $TAHOE_DIR/Maildir ]; then
|
||||||
rm -rf $TAHOE_DIR/Maildir
|
rm -rf $TAHOE_DIR/Maildir
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -355,7 +355,8 @@ function remove_turtl {
|
||||||
remove_app turtl
|
remove_app turtl
|
||||||
remove_completion_param install_turtl
|
remove_completion_param install_turtl
|
||||||
sed -i '/turtl/d' $COMPLETION_FILE
|
sed -i '/turtl/d' $COMPLETION_FILE
|
||||||
deluser turtl
|
deluser --remove-all-files turtl
|
||||||
|
delgroup turtl
|
||||||
nginx_dissite $TURTL_DOMAIN_NAME
|
nginx_dissite $TURTL_DOMAIN_NAME
|
||||||
if [ -f /etc/nginx/sites-available/$TURTL_DOMAIN_NAME ]; then
|
if [ -f /etc/nginx/sites-available/$TURTL_DOMAIN_NAME ]; then
|
||||||
rm /etc/nginx/sites-available/$TURTL_DOMAIN_NAME
|
rm /etc/nginx/sites-available/$TURTL_DOMAIN_NAME
|
||||||
|
@ -562,6 +563,7 @@ __ENDCONFIG__
|
||||||
fi
|
fi
|
||||||
|
|
||||||
adduser --disabled-login --home=$TURTL_BASE_DIR --gecos 'turtl' turtl
|
adduser --disabled-login --home=$TURTL_BASE_DIR --gecos 'turtl' turtl
|
||||||
|
groupadd turtl
|
||||||
chown -R turtl:turtl $TURTL_BASE_DIR
|
chown -R turtl:turtl $TURTL_BASE_DIR
|
||||||
|
|
||||||
if [[ "$check_architecture" != *"arm"* ]]; then
|
if [[ "$check_architecture" != *"arm"* ]]; then
|
||||||
|
|
Loading…
Reference in New Issue