Skip to content
Snippets Groups Projects
Commit f2de19b5 authored by Miniontoby's avatar Miniontoby :writing_hand_tone1:
Browse files
parents c25322c2 ed64ab23
No related branches found
No related tags found
No related merge requests found
# Requirements
You need to have installed the following:
- git
- webserver (apache2 recommended)
- php
- mariadb
- php-mysqli
# Install
Start by cloning the repo:
```
git clone https://edugit.org/TheDutchProgrammers/MySchoolDay.git /var/www/html/MySchoolDay
cd /var/www/html/MySchoolDay
```
# Database
Start by executing: (whilst in `/var/www/html/MySchoolDay`)
`$ mysql -u root -p < ./myschoolday.sql`
Fill in your root password. If it doesn't give any errors, then the database is created!
For security reasons I would recommend creating an user for the database instead of using the root user. You can do this by executing the following commands:
`$ mysql -u root -p`
Fill in the root password again, but now you will see something like this:
```
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is ##
Server version: 10.5.12-MariaDB-0+deb11u1 Debian 11
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]>
```
Now type in the line you see the following:
```
CREATE USER 'myschoolday'@'localhost' IDENTIFIED BY 'CREATE_YOUR_OWN_PASSWORD';
GRANT ALL PRIVILEGES ON myschoolday.* TO 'myschoolday'@'localhost';
FLUSH PRIVILEGES;
```
Now press CTRL-D and you will be back in your commandline
# Configuration
Go into the `public/config/` folder and copy the `config.template.ini` to `config.ini`
Make the following changes:
At `[database]`:
- Change db_host to `localhost`
- Change db_user to `myschoolday`
- Change db_password to the chosen password
- Change db_name to `myschoolday`
At `[application]`:
- Change app_email to the email which will be used in the futher for sending emails
- Change app_domain to the domain where your webserver is binded to
- Change app_folder to the folder where your myschoolday is located (E.G. /MySchoolDay/ or /) Note: ALWAYS WITH TRAILING SLASH!!!
- Change app_language to your wanted language (check public/locale for all supported languages)
- Change app_secret to some thing completely random: this is used for logging in
At `[notification]` you dont have to change anything, since it is still experimental.
# Webserver
At your webserver you need to allow URLRewriting
Apache2:
```
<Directory /var/www/html/MySchoolDay/>
AllowOverride All
Require all granted
</Directory>
```
# open your broemwse
Try to go to your webserver and at the folder you have put it in and see if it works
click on the login icon on the left and use "Test School" as school name and 1 as username and 12345 as password
then refresh the page if it doesnt redirect you. and the sidebar should be filled with things you can try out.
LICENSE 0 → 100644
This diff is collapsed.
# MySchoolDay # MySchoolDay
A school roster project for yh4f A school roster project for YH4F
# Usage:
## Config # How to install it
Make sure to edit the config. Check INSTALL.md for the details
Copy the template `cp public/config/config.template.ini public/config/config.ini`
And edit the copied file `public/config/config.ini` # What is it?
It is a school roster program written in PHP by TheDutchProgrammers for the competition of FSFE (Free Software Foundation Europe) called YH4F (Youth Hacking 4 Freedom)
## Setup
For apache2 make sure to have the directory block like this:
```
<Directory /folder/to/myschoolday/>
AllowOverride All
Require all granted
</Directory>
```
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment