2024-09-07 16:57:09 -06:00
|
|
|
================
|
|
|
|
civicrm.libre.is
|
|
|
|
================
|
|
|
|
CiviCRM deployment.
|
|
|
|
|
|
|
|
`<https://civicrm.libre.is/>`_
|
|
|
|
|
|
|
|
Under consideration:
|
|
|
|
|
|
|
|
`<https://crm.libre.is/>`_
|
|
|
|
|
|
|
|
CiviCRM
|
|
|
|
=======
|
|
|
|
CiviCRM is a "constituent relationship management software" for
|
|
|
|
especially designed for non-profits.
|
|
|
|
|
|
|
|
`<https://civicrm.org/>`_
|
|
|
|
|
|
|
|
|
|
|
|
Drupal
|
|
|
|
======
|
|
|
|
CiviCRM works with various backends such as Drupal, Joomla, and Wordpress.
|
|
|
|
|
|
|
|
Drupal is the most powerful.
|
|
|
|
|
|
|
|
`<https://www.drupal.org/>`_
|
|
|
|
|
2024-09-08 12:01:59 -06:00
|
|
|
Drupal needs to be installed before CiviCRM.
|
|
|
|
|
|
|
|
Install Debian stable (bookworm/12) with Apache and set up Certbot.
|
|
|
|
|
2024-09-17 12:41:52 -06:00
|
|
|
Wordpress
|
|
|
|
=========
|
|
|
|
The test install will have a CiviCRM with Wordpress install.
|
|
|
|
|
|
|
|
`<https://docs.civicrm.org/installation/en/latest/wordpress/>`_
|
|
|
|
|
2024-09-17 13:00:17 -06:00
|
|
|
`<https://developer.wordpress.org/advanced-administration/before-install/howto-install/>`_
|
2024-09-17 12:41:52 -06:00
|
|
|
|
|
|
|
Download latest release:
|
|
|
|
|
|
|
|
`<https://wordpress.org/latest.zip>`_
|
|
|
|
|
|
|
|
.. code-block:: sh
|
|
|
|
|
2024-09-17 13:00:17 -06:00
|
|
|
sudo apt install unzip python3-certbot-apache php mariadb-server php-mysql
|
2024-09-17 12:41:52 -06:00
|
|
|
|
|
|
|
Set up the database.
|
|
|
|
|
|
|
|
.. code-block:: sh
|
|
|
|
|
|
|
|
sudo mariadb-admin password
|
|
|
|
mariadb -uroot -p
|
|
|
|
|
|
|
|
Then in the database:
|
|
|
|
|
|
|
|
.. code-block:: sql
|
|
|
|
|
|
|
|
CREATE USER 'wordpress'@'localhost' IDENTIFIED BY 'password';
|
|
|
|
CREATE DATABASE IF NOT EXISTS wordpress CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
|
|
|
|
GRANT ALL PRIVILEGES on wordpress.* to 'wordpress'@'localhost';
|
|
|
|
FLUSH PRIVILEGES;
|
|
|
|
EXIT
|
2024-09-08 12:01:59 -06:00
|
|
|
|
2024-09-17 13:00:17 -06:00
|
|
|
Perhaps change the ownership to your user (in this case jebba)
|
|
|
|
to install wordpress files. Then unzip wordpress and move to
|
|
|
|
the best location:
|
|
|
|
|
|
|
|
.. code-block:: sh
|
|
|
|
|
2024-09-17 13:17:34 -06:00
|
|
|
sudo chown -R jebba:jebba /var/www
|
|
|
|
cd /var/www/
|
2024-09-17 13:00:17 -06:00
|
|
|
unzip ~/devel/wordpress/latest.zip
|
2024-09-17 13:17:34 -06:00
|
|
|
sudo chown -R www-data /var/www/wordpress
|
2024-09-17 13:00:17 -06:00
|
|
|
|
2024-09-17 13:17:34 -06:00
|
|
|
Set up apache, perhaps thusly:
|
2024-09-17 13:00:17 -06:00
|
|
|
|
2024-09-17 13:17:34 -06:00
|
|
|
.. code-block:: sh
|
|
|
|
|
|
|
|
rm /etc/apache2/sites-enabled/000-default*
|
|
|
|
|
|
|
|
Edit /etc/apache2/sites-available/wordpress.conf
|
|
|
|
|
|
|
|
.. code-block:: apache
|
|
|
|
|
|
|
|
<VirtualHost 70.39.82.212:80>
|
|
|
|
ServerName civicrm.libre.is
|
|
|
|
ServerAdmin webmaster@localhost
|
|
|
|
DocumentRoot /var/www/wordpress
|
|
|
|
ErrorLog ${APACHE_LOG_DIR}/error-civicrm-libre-is.log
|
|
|
|
CustomLog ${APACHE_LOG_DIR}/access-civicrm-libre-is.log combined
|
|
|
|
RewriteEngine on
|
|
|
|
ReWriteCond %{HTTPS} off
|
|
|
|
RewriteRule ^ https://civicrm.libre.is%{REQUEST_URI} [END,NE,R=permanent]
|
|
|
|
ReWriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
|
|
|
|
RewriteCond %{SERVER_NAME} =civicrm.libre.is
|
|
|
|
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
|
|
|
|
</VirtualHost>
|
|
|
|
|
|
|
|
<VirtualHost 70.39.82.212:443>
|
|
|
|
ServerName civicrm.libre.is
|
|
|
|
ServerAdmin webmaster@localhost
|
|
|
|
DocumentRoot /var/www/html/civicrm-libre-is
|
|
|
|
ErrorLog ${APACHE_LOG_DIR}/error-civicrm-libre-is.log
|
|
|
|
CustomLog ${APACHE_LOG_DIR}/access-civicrm-libre-is.log combined
|
|
|
|
RewriteEngine on
|
|
|
|
ReWriteCond %{HTTPS} off [OR]
|
|
|
|
ReWriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
|
|
|
|
ReWriteRule ^(.*)$ https://%1$1 [L,R=301]
|
|
|
|
ErrorDocument 404 /en/404.html
|
|
|
|
Include /etc/letsencrypt/options-ssl-apache.conf
|
|
|
|
ServerAlias doc.libre.is
|
|
|
|
SSLCertificateFile /etc/letsencrypt/live/civicrm.libre.is/fullchain.pem
|
|
|
|
SSLCertificateKeyFile /etc/letsencrypt/live/civicrm.libre.is/privkey.pem
|
|
|
|
</VirtualHost>
|
|
|
|
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet
|
|
|
|
|
|
|
|
|
|
|
|
.. code-block:: sh
|
|
|
|
|
|
|
|
sudo ln -s /etc/apache2/sites-available/wordpress.conf \
|
|
|
|
/etc/apache2/sites-enabled/
|
|
|
|
sudo systemctl restart apache2
|