Coordinatorr Installation #
Step 0: Get a domain, or a subdomain #
You’ll need one for this piece of software. The internet provides plenty of options.
Step 1: Install Apache, PHP and Composer #
If you are using shared hosting, skip this step, but make sure composer exists on your hosting provider.
If not, this is just the list of commands to install all those prerequisites on a new blank current Ubuntu system. You’ll find plenty of extensive tutorials on how to do that, this is just here to get you started asap.
sudo apt-get update -y
sudo apt-get install apache2 -y
sudo add-apt-repository -y ppa:ondrej/php
sudo apt-get update -y
sudo apt-get install libapache2-mod-php php php-common php-xml php-mysql php-pgsql php-gd php-opcache php-mbstring php-tokenizer php-json php-bcmath php-zip php-sqlite unzip -y
sudo a2enmod rewrite
sudo service apache2 restart
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
composer --version
If you like to use MySQL instead of SQLITE as a backend, also install MySQL. But pleeeease don’t, you WILL NOT need that. SQLite is plenty enough for Coordinatorr.
Step 2: Configure Apache #
If you are using shared hosting, set the root folder of the webpage to the public
subfolder and skip the rest of this step.
If not, create a vhost configuration file for coordinatorr. Of course, you can substitute the name of the file with whatever you like:
sudo nano /etc/apache2/sites-available/coordinatorr.conf
In the file, create the virtual host. Of course, customize directories, Domains and Admin-Emails to your liking.
<VirtualHost *:80>
ServerAdmin admin@example.com
ServerName mydomain.com
DocumentRoot "/var/www/coordinatorr/public"
<Directory /var/www/coordinatorr/public>
Options Indexes MultiViews FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Activate the site and reload apache
sudo a2ensite coordinatorr.conf
sudo service apache2 restart
Step 3: Install coordinatorr #
Clone this repo, install all dependencies, copy you environment file and generate your app key.
If you are using shared hosting, scrap the sudo -u www-data
part from each command from here (also in the following steps).
cd /var/www
sudo -u www-data git clone https://github.com/DB4SCW/coordinatorr coordinatorr
cd coordinatorr
sudo -u www-data composer install --no-dev
sudo -u www-data cp .env.example .env
sudo -u www-data php artisan key:generate
Open the .env file:
nano .env
Change the database configuration, depending on your choice of database. Again, please, for the love of god, use SQLite for Coordinator ;)
SQLITE #
Please change the values to reflect your installation. DB_DATABASE is the filename of your sqlite file inside the database
subdirectory:
DB_CONNECTION=sqlite
DB_DATABASE=database.sqlite
Afterwards, create the sqlite file:
sudo -u www-data touch /var/www/coordinatorr/database/database.sqlite
Step 4: Configure your software environment #
Have a look at the rest of the env file and change other values according to your needs, e.g.:
- APP_ENV (e.g. production or local -> for actual live service, choose production)
- APP_DEBUG (set to false to hide internal errors -> please do that in live service)
- APP_URL (your URL)
- APP_IMPRESSUM_URL (sets the impressum url in the footer, defaults to homepage if empty)
- APP_DATA_PROTECTION_URL (sets the data protection declaration url in the footer, defaults to homepage if empty)
- ADMIN_PANEL_SECRET (sets the secret URL to open the admin panel, choose a single word which is not obvious but you remember)
- COORDINATORR_CHECK_RESERVATIONS_IN_ADVANCE_HOURS (sets how much in advance coordinator checks for upcoming reservations for warning)
If you like, you can place a file called privacy.html
in the public
folder of coordinatorr to contain your data protection declaration. You can link there in APP_DATA_PROTECTION_URL
like this: https://your.site.here/privacy.html
.
If you like, you can place a file called impressum.html
in the public
folder of coordinatorr to contain your impressum. You can link there in APP_IMPRESSUM_URL
like this: https://your.site.here/impressum.html
.
Those two exact(!) file names are explicitly allowed to be placed there and will NOT be overwritten by any future update.
Step 5: Prepare the database #
Migrate the database and create the link for internal storage. After that, restart apache for good measure.
cd /var/www/coordinatorr
sudo -u www-data php artisan migrate
sudo -u www-data php artisan storage:link
sudo service apache2 restart
Step 6: Secure your coordinatorr installation #
Configure your apache server with a Let’s Encrypt SSL certificate using certbot (plenty of guides out there), or place your install behind a reverse proxy (if you choose that, I think you know what to do already).
Step 7: Finished #
Login to Coordinator by using the special link you specified in .env by appending by opening https://your.domain.com/adminkey/WHATEVERYOUSPECIFIED
, by replacing WHATEVERYOUSPECIFIED with the value of ADMIN_PANEL_SECRET
from your .env file.
Have fun!
Updating coordinatorr to a new version #
Just cd into your folder, git pull and afterwards, migrate the database. You are up and running the newest version!
If you are using shared hosting, scrap the sudo -u www-data
part from each command.
cd /var/www/coordinatorr
sudo -u www-data git pull origin master --rebase
sudo -u www-data php artisan migrate
sudo -u www-data composer install