mirror of
https://github.com/michaelstaake/mainty.git
synced 2026-04-17 03:50:13 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b0dec9d3e3 | ||
|
|
444c94c898 | ||
|
|
a4cf82a470 | ||
|
|
cce8dacea6 | ||
|
|
4b6315ce6b |
11
DOCKER.md
11
DOCKER.md
@@ -126,8 +126,6 @@ For production:
|
|||||||
Example production `docker-compose.yml`:
|
Example production `docker-compose.yml`:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
mainty:
|
mainty:
|
||||||
build: .
|
build: .
|
||||||
@@ -136,12 +134,9 @@ services:
|
|||||||
- "8080:80"
|
- "8080:80"
|
||||||
volumes:
|
volumes:
|
||||||
- ./data:/var/www/html/data
|
- ./data:/var/www/html/data
|
||||||
|
# Uncomment below to sync code changes in development
|
||||||
|
# - .:/var/www/html
|
||||||
environment:
|
environment:
|
||||||
- APACHE_DOCUMENT_ROOT=/var/www/html
|
- APACHE_DOCUMENT_ROOT=/var/www/html
|
||||||
restart: always
|
restart: unless-stopped
|
||||||
logging:
|
|
||||||
driver: "json-file"
|
|
||||||
options:
|
|
||||||
max-size: "10m"
|
|
||||||
max-file: "3"
|
|
||||||
```
|
```
|
||||||
|
|||||||
10
README.md
10
README.md
@@ -4,21 +4,29 @@ A simple PHP web app for tracking vehicle maintenance records. Free, easy, respo
|
|||||||
|
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
|
- If you're using Docker, these requirements should be handled automatically, and you don't need to worry about them:
|
||||||
- Apache web server
|
- Apache web server
|
||||||
- PHP 8 or higher
|
- PHP 8 or higher
|
||||||
- SQLite extension
|
- SQLite extension
|
||||||
- If you're using Docker, these requirements should be handled automatically, and you don't need to worry about it.
|
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
### Option 1: Docker
|
### Option 1: Docker
|
||||||
|
|
||||||
|
Once you have Docker working on your system, enter the directory where you have placed Mainty and run the following command to start the services:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker-compose up -d
|
docker-compose up -d
|
||||||
```
|
```
|
||||||
|
|
||||||
Then open http://localhost:8080
|
Then open http://localhost:8080
|
||||||
|
|
||||||
|
When you are done using Mainty, you can run the following command to stop the services:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker-compose down
|
||||||
|
```
|
||||||
|
|
||||||
### Option 2: Traditional Web Server
|
### Option 2: Traditional Web Server
|
||||||
|
|
||||||
1. Upload the entire folder to your web server
|
1. Upload the entire folder to your web server
|
||||||
|
|||||||
@@ -1,5 +1,3 @@
|
|||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
mainty:
|
mainty:
|
||||||
build: .
|
build: .
|
||||||
|
|||||||
@@ -2,6 +2,9 @@ RewriteEngine On
|
|||||||
#if this is in a folder, edit this. example.com/mainty/ would be /mainty/
|
#if this is in a folder, edit this. example.com/mainty/ would be /mainty/
|
||||||
RewriteBase /
|
RewriteBase /
|
||||||
|
|
||||||
|
# Block access to data directory
|
||||||
|
RewriteRule ^data/ - [F,L]
|
||||||
|
|
||||||
# Redirect to HTTPS (optional, uncomment if needed)
|
# Redirect to HTTPS (optional, uncomment if needed)
|
||||||
# RewriteCond %{HTTPS} off
|
# RewriteCond %{HTTPS} off
|
||||||
# RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
|
# RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
|
||||||
|
|||||||
Reference in New Issue
Block a user