Move some installation steps from readme to instll script

This commit is contained in:
2022-07-02 21:05:48 +02:00
parent c61f70b378
commit e0bbda7182
2 changed files with 26 additions and 11 deletions

View File

@ -111,13 +111,7 @@ Install sodium_compat for v3 hidden_service support
cd /var/www && composer install
```
For web base database administration, check out the latest phpmyadmin and adminer:
```
cd /var/www/html/ && git clone -b STABLE https://github.com/phpmyadmin/phpmyadmin/ && cd phpmyadmin && composer install --no-dev && yarn
cd /var/www/html/ && git clone https://github.com/vrana/adminer/ && cd adminer && git submodule update --init
```
Once installed create a mysql user for phpmyadmin and cofigure it in `/var/www/html/phpmyadmin/config.inc.php` and fill `$cfg['blowfish_secret']` with random characters:
Create a mysql user for phpmyadmin and cofigure it in `/var/www/html/phpmyadmin/config.inc.php` and fill `$cfg['blowfish_secret']` with random characters:
```
mysql
CREATE USER 'phpmyadmin'@'%' IDENTIFIED BY 'MY_PASSWORD';
@ -128,12 +122,12 @@ quit
mysql phpmyadmin < /var/www/html/phpmyadmin/sql/create_tables.sql
```
For web based mail management grab the latest squirrelmail and install it in `/var/www/html/squirrelmail`:
For web based mail management configure squirrelmail:
```
cd /var/www/html/ && git clone https://github.com/RealityRipple/squirrelmail && cd squirrelmail && mkdir -p /var/www/data/squirrelmail/data /var/www/data/squirrelmail/attach && chown www-data:www-data -R /var/www/data && ./configure
cd /var/www/html/squirrelmail && ./configure
```
Once it is downloaded, it will ask you for configuration. Things to change are:
Configuration options to change are:
```
D. > select dovecot
2. Server Settings > 1. Domain > Set your own .onion domain here

View File

@ -13,7 +13,6 @@ DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends install -y autoco
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# install nodejs
nvm install node
@ -1836,3 +1835,25 @@ if [ ! -e /etc/mysql/encryption/keyfile.enc ]; then
openssl rand -hex 128 > /etc/mysql/encryption/keyfile.key
echo "1;"$(openssl rand -hex 32) | openssl enc -aes-256-cbc -md sha1 -pass file:/etc/mysql/encryption/keyfile.key -out /etc/mysql/encryption/keyfile.enc
fi
# install php applications
if [ ! -e /var/www/html/phpmyadmin ]; then
mkdir -p /var/www/html/phpmyadmin
cd /var/www/html/phpmyadmin
git clone -b STABLE https://github.com/phpmyadmin/phpmyadmin/ .
composer install --no-dev
yarn
fi
if [ ! -e /var/www/html/adminer ]; then
mkdir -p /var/www/html/adminer
cd /var/www/html/adminer
git clone https://github.com/vrana/adminer/ .
git submodule update --init
fi
if [ ! -e /var/www/html/squirrelmail ]; then
mkdir -p /var/www/html/squirrelmail
cd /var/www/html/squirrelmail
git clone https://github.com/RealityRipple/squirrelmail .
mkdir -p /var/www/data/squirrelmail/data /var/www/data/squirrelmail/attach
chown www-data:www-data -R /var/www/data
fi