This repository contains a simple login system template.
- Download the
docker-compose.yml
file or clone the whole repository:
git clone git@github.com:Malte311/Loginsystem.git
- Adjust the
docker-compose.yml
file. Specify the correct url and adjust the port.
version: "2"
services:
web:
image: quay.io/malte311/loginsystem:latest
container_name: loginsystem
ports:
- "127.0.0.1:8080:80"
volumes:
- ./data/:/php-code/data/
restart: always
environment:
- SERVERURL=https://example.com/loginsystem
- Get the newest Docker image and start a Docker container (inside of the project folder):
docker-compose pull
docker-compose up -d
In order to manage user accounts, one can use the src/userAdministration.php
file. This file allows the admin to add new users, change passwords of users, delete users or list all existing users. It can be used as follows:
php userAdministration.php add
Asks for a username and password and adds a new user to the system.php userAdministration.php edit
Asks for a user id and allows to change the password or to generate an authentication code for that user.php userAdministration.php delete
Asks for a user id and deletes that user.php userAdministration.php list
Lists all existing usernames with their corresponding ids.
Currently, there is no support for the users to change their password by themselves. There is no interface for user administration, only a simple console script in order to keep things simple.
In order to adjust the name of the application, simply replace the term 'Loginsystem' in the .html
files.
This project is licensed under the terms of the MIT License.