Line 1... |
Line 1... |
1 |
#!/bin/bash
|
1 |
#!/bin/bash
|
2 |
# $Id: alcasar-conf.sh 2745 2019-07-28 22:11:33Z rexy $
|
2 |
# $Id: alcasar-conf.sh 2811 2020-04-15 22:07:11Z rexy $
|
3 |
|
3 |
|
4 |
# alcasar-conf.sh
|
4 |
# alcasar-conf.sh
|
5 |
# by REXY
|
5 |
# by REXY
|
6 |
# This script is distributed under the Gnu General Public License (GPL)
|
6 |
# This script is distributed under the Gnu General Public License (GPL)
|
7 |
|
7 |
|
Line 193... |
Line 193... |
193 |
cp -f $DIR_UPDATE/alcasar-ca.key /etc/pki/CA/private/
|
193 |
cp -f $DIR_UPDATE/alcasar-ca.key /etc/pki/CA/private/
|
194 |
cp -f $DIR_UPDATE/alcasar.crt /etc/pki/tls/certs/
|
194 |
cp -f $DIR_UPDATE/alcasar.crt /etc/pki/tls/certs/
|
195 |
cp -f $DIR_UPDATE/alcasar.key /etc/pki/tls/private/
|
195 |
cp -f $DIR_UPDATE/alcasar.key /etc/pki/tls/private/
|
196 |
cp -f $DIR_UPDATE/alcasar.pem /etc/pki/tls/private/
|
196 |
cp -f $DIR_UPDATE/alcasar.pem /etc/pki/tls/private/
|
197 |
[ -e $DIR_UPDATE/server-chain.crt ] && cp -f $DIR_UPDATE/server-chain.crt* /etc/pki/tls/certs/ # autosigned and official if exist
|
197 |
[ -e $DIR_UPDATE/server-chain.crt ] && cp -f $DIR_UPDATE/server-chain.crt* /etc/pki/tls/certs/ # autosigned and official if exist
|
198 |
chown -R root:apache /etc/pki
|
198 |
chown root:apache /etc/pki/CA; chmod 750 /etc/pki/CA
|
199 |
chmod -R 750 /etc/pki
|
199 |
chmod 640 /etc/pki/CA/*
|
- |
|
200 |
chown root:root /etc/pki/CA/private; chmod 700 /etc/pki/CA/private
|
- |
|
201 |
chmod 600 /etc/pki/CA/private/*
|
- |
|
202 |
chown -R root:apache /etc/pki/tls/private; chmod 750 /etc/pki/tls/private
|
- |
|
203 |
chmod 640 /etc/pki/tls/private/*
|
200 |
# Import of the users database
|
204 |
# Import of the users database
|
201 |
$DIR_BIN/alcasar-mysql.sh --import "$(ls $DIR_UPDATE/alcasar-users-database*)"
|
205 |
$DIR_BIN/alcasar-mysql.sh --import "$(ls $DIR_UPDATE/alcasar-users-database*)"
|
202 |
# Retrieve local parameters
|
206 |
# Retrieve local parameters
|
203 |
cp -rf $DIR_UPDATE/etc/* $DIR_ETC/
|
207 |
cp -rf $DIR_UPDATE/etc/* $DIR_ETC/
|
204 |
mv -f $DIR_UPDATE/etc/hosts /etc/hosts
|
208 |
mv -f $DIR_UPDATE/etc/hosts /etc/hosts
|