update README
This commit is contained in:
@@ -30,52 +30,54 @@ EOF
|
|||||||
DocumentRoot /var/www/cagettepei/www/
|
DocumentRoot /var/www/cagettepei/www/
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
```
|
```
|
||||||
* sed -i '/<Directory \/var\/www\/>/,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /etc/apache2/apache2.conf
|
* sed -i '/<Directory \/var\/www\/>/,/<\/Directory>/ s/AllowOverride None/AllowOverride All/' /etc/apache2/apache2.conf
|
||||||
* a2dissite 000-default.conf
|
* a2dissite 000-default.conf
|
||||||
* a2ensite cagettepei.conf
|
* a2ensite cagettepei.conf
|
||||||
* a2enmod neko rewrite
|
* a2enmod neko rewrite
|
||||||
* systemctl restart apache2
|
* systemctl restart apache2
|
||||||
|
|
||||||
## CONFIGURATION
|
## CONFIGURATION
|
||||||
|
|
||||||
* cd /var/www/cagettepei
|
* cd /var/www/cagettepei
|
||||||
* vim config.xml
|
* vim config.xml
|
||||||
```
|
```
|
||||||
<config
|
<config
|
||||||
host="<DOMAIN.TLD>"
|
host="<DOMAIN.TLD>"
|
||||||
key="<SECRET_PHRASE>"
|
key="<SECRET_PHRASE>"
|
||||||
name = "CagettePéi"
|
name = "CagettePéi"
|
||||||
default_email = "<EMAIL>"
|
default_email = "<EMAIL>"
|
||||||
webmaster_email = "<EMAIL>"
|
webmaster_email = "<EMAIL>"
|
||||||
database="mysql://cagettepei:cagettepei@localhost/cagettepei"
|
database="mysql://cagettepei:cagettepei@localhost/cagettepei"
|
||||||
|
|
||||||
smtp_host="localhost"
|
smtp_host="localhost"
|
||||||
smtp_port="25"
|
smtp_port="25"
|
||||||
smtp_user=""
|
smtp_user=""
|
||||||
smtp_pass=""
|
smtp_pass=""
|
||||||
|
|
||||||
lang="fr"
|
lang="fr"
|
||||||
langs="fr"
|
langs="fr"
|
||||||
langnames="Français"
|
langnames="Français"
|
||||||
maintain="0"
|
maintain="0"
|
||||||
debug="0"
|
debug="0"
|
||||||
sqllog="0"
|
sqllog="0"
|
||||||
cache="1"
|
cache="1"
|
||||||
cachetpl="0"
|
cachetpl="0"
|
||||||
/>
|
/>
|
||||||
```
|
```
|
||||||
|
|
||||||
ADMIN RESET PASSWORD
|
ADMIN RESET PASSWORD
|
||||||
--------------------
|
--------------------
|
||||||
|
|
||||||
* # go to http://localhost for ERROR + table regeneration, then
|
go to http://localhost for ERROR + table regeneration, then
|
||||||
|
|
||||||
* cd /var/www/cagettepei
|
* cd /var/www/cagettepei
|
||||||
* SECRET=$(grep key= config.xml | cut -d= -f2 | cut -d'"' -f2)
|
* SECRET=$(grep key= config.xml | cut -d= -f2 | cut -d'"' -f2)
|
||||||
* echo "insert into User values (1,'fr',MD5('${SECRET}cagettepei'),1,'Administrateur','Cagette Péi', 'admin', null, null, null, null, null, null, null, null, null, now(), now(),6,null, null)" | mysql -h localhost -u cagettepei -pcagettepei cagettepei
|
* echo "insert into User values (1,'fr',MD5('${SECRET}cagettepei'),1,'Administrateur','Cagette Péi', 'admin', null, null, null, null, null, null, null, null, null, now(), now(),6,null, null)" | mysql -h localhost -u cagettepei -pcagettepei cagettepei
|
||||||
* # connect with admin / cagettepei
|
|
||||||
|
|
||||||
|
then, connect with admin / cagettepei
|
||||||
|
|
||||||
|
### change admin password
|
||||||
|
|
||||||
* # change admin password
|
|
||||||
* echo "update User set pass=MD5('${SECRET}cagettepei') where id=1" | mysql -h localhost -u cagettepei -pcagettepei cagettepei
|
* echo "update User set pass=MD5('${SECRET}cagettepei') where id=1" | mysql -h localhost -u cagettepei -pcagettepei cagettepei
|
||||||
|
|
||||||
|
|
||||||
@@ -118,6 +120,7 @@ ExecStart=/var/www/cagettepei-batch minute
|
|||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
```
|
```
|
||||||
|
|
||||||
* vim /etc/systemd/system/cagettepei-batch-day.service
|
* vim /etc/systemd/system/cagettepei-batch-day.service
|
||||||
```
|
```
|
||||||
[Unit]
|
[Unit]
|
||||||
@@ -131,6 +134,7 @@ ExecStart=/var/www/cagettepei-batch daily
|
|||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
```
|
```
|
||||||
|
|
||||||
* vim /etc/systemd/system/cagettepei-batch-minute.timer
|
* vim /etc/systemd/system/cagettepei-batch-minute.timer
|
||||||
```
|
```
|
||||||
[Unit]
|
[Unit]
|
||||||
@@ -144,6 +148,7 @@ Unit=cagettepei-batch-minute.service
|
|||||||
[Install]
|
[Install]
|
||||||
WantedBy=timers.target
|
WantedBy=timers.target
|
||||||
```
|
```
|
||||||
|
|
||||||
* vim /etc/systemd/system/cagettepei-batch-day.timer
|
* vim /etc/systemd/system/cagettepei-batch-day.timer
|
||||||
```
|
```
|
||||||
[Unit]
|
[Unit]
|
||||||
@@ -159,12 +164,9 @@ WantedBy=timers.target
|
|||||||
```
|
```
|
||||||
* systemctl daemon-reload
|
* systemctl daemon-reload
|
||||||
* systemctl edit apache2 # bind the 2 timers to apache2 cagette
|
* systemctl edit apache2 # bind the 2 timers to apache2 cagette
|
||||||
```
|
```
|
||||||
[Unit]
|
[Unit]
|
||||||
BindsTo = cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
BindsTo = cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
||||||
```
|
```
|
||||||
* systemctl enable cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
* systemctl enable cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
||||||
* systemctl start cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
* systemctl start cagettepei-batch-minute.timer cagettepei-batch-day.timer
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user