Update docs/source/install.rst
This commit is contained in:
parent
83a54bbe10
commit
5fa9f0b479
|
@ -2,6 +2,12 @@ Install
|
|||
=======
|
||||
|
||||
|
||||
Requirements
|
||||
-----------------------
|
||||
|
||||
QuartzMap requires only a LAPP stack.
|
||||
|
||||
|
||||
Installation on Ubuntu 22
|
||||
--------------------------------
|
||||
|
||||
|
@ -169,19 +175,30 @@ Configure Apache
|
|||
.. code-block:: bash
|
||||
|
||||
a2enmod ssl headers expires fcgid cgi
|
||||
|
||||
Copy the apache2.conf file to sites-available/default-ssl.conf (or use own config)
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
cp installer/apache2.conf /etc/apache2/sites-available/default-ssl.conf
|
||||
|
||||
# Below is required for Certbot to provision SSL
|
||||
Below is required for Certbot to provision SSL
|
||||
|
||||
.. code-block:: bash
|
||||
for f in 000-default default-ssl; do
|
||||
sed -i.save "s/#ServerName example.com/#ServerName ${HNAME}/" /etc/apache2/sites-available/${f}.conf
|
||||
done
|
||||
|
||||
Enable confs and reload Apache
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
a2ensite 000-default default-ssl
|
||||
systemctl reload apache2
|
||||
|
||||
Request certificate from Let's Encrypt:
|
||||
Request certificate from Let's Encrypt
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
certbot --apache --agree-tos --email hostmaster@${HNAME} --no-eff-email -d ${HNAME}
|
||||
|
||||
|
@ -189,13 +206,20 @@ Request certificate from Let's Encrypt:
|
|||
Create Data and Cache Directories
|
||||
----------------------------
|
||||
|
||||
Set the DATA_DIR outside of public directories
|
||||
Set the DATA_DIR and CACHE_DIR should be outside of public directories
|
||||
|
||||
For example /var/www
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
mkdir -p "${APPS_DIR}"
|
||||
mkdir -p "${CACHE_DIR}"
|
||||
mkdir -p "${DATA_DIR}"
|
||||
mkdir -p /var/www/cache
|
||||
mkdir -p /var/www/data
|
||||
|
||||
Create the apps directory
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
mkdir -p /var/www/html/apps
|
||||
|
||||
|
||||
Grant Apache permissions
|
||||
|
@ -247,25 +271,30 @@ Create incl/const.php file
|
|||
|
||||
Copy the incl/const.php.dist file
|
||||
|
||||
.. code-block:: php
|
||||
|
||||
cp const.php.dist const.php
|
||||
|
||||
Populate using values from above.
|
||||
|
||||
.. code-block:: php
|
||||
|
||||
cat >admin/incl/const.php <<CAT_EOF
|
||||
<?php
|
||||
define("DB_HOST", "localhost");
|
||||
define("DB_NAME", "${APP_DB}");
|
||||
define("DB_USER", "${APP_DB}");
|
||||
define("DB_PASS", "${APP_DB_PASS}");
|
||||
define("DB_PORT", 5432);
|
||||
define("DB_SCMA", 'public');
|
||||
define("APPS_DIR", "${APPS_DIR}");
|
||||
define("CACHE_DIR", "${CACHE_DIR}");
|
||||
define("DATA_DIR", "${DATA_DIR}");
|
||||
define("SUPER_ADMIN_ID", 1);
|
||||
define("SESS_USR_KEY", 'q2w_user');
|
||||
?>
|
||||
CAT_EOF
|
||||
<?php
|
||||
define("DB_HOST", "localhost");
|
||||
define("DB_NAME", "quartz");
|
||||
define("DB_USER", "quartz");
|
||||
define("DB_PASS", "SuperSecretPassword");
|
||||
define("DB_PORT", 5432);
|
||||
define("DB_SCMA", 'public');
|
||||
define("APPS_DIR", "/var/www/html/apps");
|
||||
define("CACHE_DIR", "/var/www/cache");
|
||||
define("DATA_DIR", "/var/www/data");
|
||||
define("SUPER_ADMIN_ID", 1);
|
||||
define("SESS_USR_KEY", 'q2w_user');
|
||||
const ACCESS_LEVELS = array('User', 'Admin');
|
||||
?>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue