mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-20 03:38:06 +02:00
Remove support for mysql
This commit is contained in:
parent
25933bd413
commit
c24f5b2708
11
Dockerfile
11
Dockerfile
@ -40,8 +40,8 @@ RUN apt-get update && \
|
|||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
# PHP
|
# PHP
|
||||||
php7.3 \
|
php7.3 \
|
||||||
# PHP SQL drivers
|
# PHP SQLite driver
|
||||||
php7.3-sqlite3 php7.3-mysql \
|
php7.3-sqlite3 \
|
||||||
# PHP extensions
|
# PHP extensions
|
||||||
php-xml php7.3-gd php7.3-mbstring \
|
php-xml php7.3-gd php7.3-mbstring \
|
||||||
# Nginx and PHP FPM to serve over HTTP
|
# Nginx and PHP FPM to serve over HTTP
|
||||||
@ -126,14 +126,9 @@ ENV \
|
|||||||
# nothing will get logged, ever.
|
# nothing will get logged, ever.
|
||||||
APP_LOG_LEVEL=notice \
|
APP_LOG_LEVEL=notice \
|
||||||
# Database config & credentials
|
# Database config & credentials
|
||||||
# DB_CONNECTION can be mysql
|
# DB_CONNECTION can only be sqlite
|
||||||
DB_CONNECTION=sqlite \
|
DB_CONNECTION=sqlite \
|
||||||
DB_DATABASE="/srv/database/database.sqlite" \
|
DB_DATABASE="/srv/database/database.sqlite" \
|
||||||
# if you want to use MySQL:
|
|
||||||
DB_HOST=127.0.0.1 \
|
|
||||||
DB_PORT=3306 \
|
|
||||||
DB_USERNAME=homestead \
|
|
||||||
DB_PASSWORD=secret \
|
|
||||||
# If you're looking for performance improvements, you could install memcached.
|
# If you're looking for performance improvements, you could install memcached.
|
||||||
CACHE_DRIVER=file \
|
CACHE_DRIVER=file \
|
||||||
SESSION_DRIVER=file \
|
SESSION_DRIVER=file \
|
||||||
|
@ -11,6 +11,7 @@ You can run 2fauth in a single Docker container.
|
|||||||
- Runs without root as user `www-data`
|
- Runs without root as user `www-data`
|
||||||
- [](https://hub.docker.com/r/2fauth/2fauth/tags)
|
- [](https://hub.docker.com/r/2fauth/2fauth/tags)
|
||||||
- Compatible with `amd64` only for now
|
- Compatible with `amd64` only for now
|
||||||
|
- Stores data in a Sqlite database file
|
||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
@ -73,12 +74,6 @@ You can also build a specific commit (see [master's commits](https://github.com/
|
|||||||
docker build -t 2fauth/2fauth https://github.com/Bubka/2FAuth.git#fba9e29bd4e3bb697296bb0bde60ae869537528b
|
docker build -t 2fauth/2fauth https://github.com/Bubka/2FAuth.git#fba9e29bd4e3bb697296bb0bde60ae869537528b
|
||||||
```
|
```
|
||||||
|
|
||||||
## Change database
|
|
||||||
|
|
||||||
If you want to change database, for example switch from SQLite to MySQL, there is no migration yet.
|
|
||||||
|
|
||||||
You might want to remove the `installed` file bind mounted in `/2fauth` so the database is re-created.
|
|
||||||
|
|
||||||
## Implementation details
|
## Implementation details
|
||||||
|
|
||||||
- The container is based on `debian:buster-slim`
|
- The container is based on `debian:buster-slim`
|
||||||
|
@ -37,15 +37,8 @@ services:
|
|||||||
# If you set it to debug your logs will grow large, and fast. If you set it to emergency probably
|
# If you set it to debug your logs will grow large, and fast. If you set it to emergency probably
|
||||||
# nothing will get logged, ever.
|
# nothing will get logged, ever.
|
||||||
- APP_LOG_LEVEL=notice
|
- APP_LOG_LEVEL=notice
|
||||||
# Database config & credentials
|
# Database config (can only be sqlite)
|
||||||
# DB_CONNECTION can be mysql
|
|
||||||
- DB_CONNECTION=sqlite
|
|
||||||
- DB_DATABASE="/srv/database/database.sqlite"
|
- DB_DATABASE="/srv/database/database.sqlite"
|
||||||
# if you want to use MySQL:
|
|
||||||
- DB_HOST=mysql
|
|
||||||
- DB_PORT=3306
|
|
||||||
- DB_USERNAME=homestead
|
|
||||||
- DB_PASSWORD=secret
|
|
||||||
# If you're looking for performance improvements, you could install memcached.
|
# If you're looking for performance improvements, you could install memcached.
|
||||||
- CACHE_DRIVER=file
|
- CACHE_DRIVER=file
|
||||||
- SESSION_DRIVER=file
|
- SESSION_DRIVER=file
|
||||||
|
Loading…
x
Reference in New Issue
Block a user