Skip to content

Philhil/DienstplanDLRG

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Actions Status Build Status

DienstplanDLRG

This Project is a Laravel based web application to manage volunteer services at the German Life Saving Society (DLRG) of Stuttgart. A production version could be found here https://dlrgdienstplan.de. If you want to register a new Client (Gliederung), just contact me.

Demo

A Demo Application is provided here: https://demo.dlrgdienstplan.de.

Login as a Admin with

user: [email protected] password: user

or as a User with

user: [email protected] password: admin

Issues & Feature requests

Before opening an issue, make sure to check whether any existing issues (open or closed) match. If you're suggesting a new feature, text me first or talk direktly to me.

Use a release!

Please refrain from using the master branch for anything else but development purposes! Use the most recent release instead. You can list all releases by running git tag and switch to one by running git checkout *name*.

Upgrade

If you run a old version follow the upgrade Guide: https://github.com/Philhil/DienstplanDLRG/wiki#upgrade-guide

License

The Laravel framework is open-sourced software licensed under the MIT license.

Setup on Debian based Linux (Server).

People with other Distros like me with Gentoo should know what to do

  • apt-get install mariadb-server nginx php phpunit php-mysql php-mbstring php-zip php-mcrypt supervisor

  • Clone this Project in your web dir like /var/www/

  • File Permissons:

  sudo chown -R www-data:www-data /path/to/your/root/directory
  sudo find /path/to/your/root/directory -type f -exec chmod 644 {} \;  
  sudo find /path/to/your/root/directory -type d -exec chmod 755 {} \;

If you run this in production please make sure to use TLS ( LetsEncrypt for Ubuntu Fanboys )

Mysql (mariadb) and Laravel

mysql_secure_installation

mysql -u root -p

CREATE DATABASE IF NOT EXISTS dlrgdienstplan;
CREATE USER 'dlrgdienstplan'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON dlrgdienstplan.* To 'dlrgdienstplan'@'localhost';

.env File

cp .env.example .env

Set the parameters in .env

DB_HOST=localhost
DB_DATABASE=dlrgdienstplan
DB_USERNAME=dlrgdienstplan
DB_PASSWORD=password

MAIL_DRIVER=smtp
MAIL_HOST=smtp.mailtrap.io
MAIL_PORT=465
MAIL_USERNAME=mailuser
MAIL_PASSWORD=pass
MAIL_ENCRYPTION=tls

FACEBOOK_CLIENTID = 000
FACEBOOK_CLIENTSECRET = 000

Setup Laravel Environment

php composer.phar install

php artisan key:generate

php artisan migrate

Create Superadmin

php artisan tinker

\App\User::create(['name' => 'LastName','first_name' => 'FirstName','email' => '[email protected]', 'password' => Hash::make('test'), 'role' => 'admin', 'approved' => '1']);

Cron and Autostart

crontab -e and paste:

* * * * * php /path-to-your-project/artisan schedule:run >> /dev/null 2>&1

Supervisor: create /etc/supervisor/conf.d/laravel-worker.conf

		
 [program:laravel-worker]		
 process_name=%(program_name)s_%(process_num)02d		
 command=php /var/www/DienstplanDLRG/artisan queue:work --tries=3		
 autostart=true		
 autorestart=true		
 numprocs=1		
 redirect_stderr=true		
 stdout_logfile=/var/log/supervisor/laravel-worker.log