aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.gitignore3
-rw-r--r--app/config/parameters.yml.dist10
-rw-r--r--docker-compose.yml25
-rw-r--r--docker/mariadb/env10
-rw-r--r--docker/php/env6
-rw-r--r--docker/postgres/env9
6 files changed, 62 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore
index 0495cb17..f88370d7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -37,5 +37,6 @@
37data/assets/* 37data/assets/*
38data/db/wallabag*.sqlite 38data/db/wallabag*.sqlite
39 39
40# Docker container logs 40# Docker container logs and data
41docker/logs/ 41docker/logs/
42docker/data/
diff --git a/app/config/parameters.yml.dist b/app/config/parameters.yml.dist
index a769bc66..0c0cbff1 100644
--- a/app/config/parameters.yml.dist
+++ b/app/config/parameters.yml.dist
@@ -1,5 +1,15 @@
1# This file is a "template" of what your parameters.yml file should look like 1# This file is a "template" of what your parameters.yml file should look like
2parameters: 2parameters:
3 # Uncomment these settings or manually update your parameters.yml
4 # to use docker-compose
5 #
6 # database_driver: %env.database_driver%
7 # database_host: %env.database_host%
8 # database_port: %env.database_port%
9 # database_name: %env.database_name%
10 # database_user: %env.database_user%
11 # database_password: %env.database_password%
12
3 database_driver: pdo_sqlite 13 database_driver: pdo_sqlite
4 database_host: 127.0.0.1 14 database_host: 127.0.0.1
5 database_port: ~ 15 database_port: ~
diff --git a/docker-compose.yml b/docker-compose.yml
index bc469419..c774b621 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -15,3 +15,28 @@ php:
15 - "9000:9000" 15 - "9000:9000"
16 volumes: 16 volumes:
17 - .:/var/www/html 17 - .:/var/www/html
18 #links:
19 # - "postgres:rdbms"
20 # - "mariadb:rdbms"
21 env_file:
22 - ./docker/php/env
23 # Comment non-used DBMS lines
24 # If all DBMS are commented out, sqlite will be used as default
25 # - ./docker/postgres/env
26 # - ./docker/mariadb/env
27#postgres:
28# image: postgres:9
29# ports:
30# - "5432:5432"
31# volumes:
32# - ./docker/data/pgsql:/var/lib/postgresql/data
33# env_file:
34# - ./docker/postgres/env
35#mariadb:
36# image: mariadb:10
37# ports:
38# - "3306:3306"
39# volumes:
40# - ./docker/data/mariadb:/var/lib/mysql
41# env_file:
42# - ./docker/mariadb/env
diff --git a/docker/mariadb/env b/docker/mariadb/env
new file mode 100644
index 00000000..87556a15
--- /dev/null
+++ b/docker/mariadb/env
@@ -0,0 +1,10 @@
1MYSQL_ROOT_PASSWORD=wallaroot
2MYSQL_USER=wallabag
3MYSQL_PASSWORD=wallapass
4MYSQL_DATABASE=wallabag
5SYMFONY__ENV__DATABASE_DRIVER=pdo_mysql
6SYMFONY__ENV__DATABASE_HOST=rdbms
7SYMFONY__ENV__DATABASE_PORT=3306
8SYMFONY__ENV__DATABASE_NAME=wallabag
9SYMFONY__ENV__DATABASE_USER=wallabag
10SYMFONY__ENV__DATABASE_PASSWORD=wallapass
diff --git a/docker/php/env b/docker/php/env
new file mode 100644
index 00000000..935134fc
--- /dev/null
+++ b/docker/php/env
@@ -0,0 +1,6 @@
1SYMFONY__ENV__DATABASE_DRIVER=pdo_sqlite
2SYMFONY__ENV__DATABASE_HOST=127.0.0.1
3SYMFONY__ENV__DATABASE_PORT=~
4SYMFONY__ENV__DATABASE_NAME=symfony
5SYMFONY__ENV__DATABASE_USER=root
6SYMFONY__ENV__DATABASE_PASSWORD=~
diff --git a/docker/postgres/env b/docker/postgres/env
new file mode 100644
index 00000000..80c78c2a
--- /dev/null
+++ b/docker/postgres/env
@@ -0,0 +1,9 @@
1POSTGRES_USER=wallabag
2POSTGRES_PASSWORD=wallapass
3POSTGRES_DB=wallabag
4export SYMFONY__ENV__DATABASE_DRIVER=pdo_pgsql
5export SYMFONY__ENV__DATABASE_HOST=rdbms
6export SYMFONY__ENV__DATABASE_PORT=5432
7export SYMFONY__ENV__DATABASE_NAME=wallabag
8export SYMFONY__ENV__DATABASE_USER=wallabag
9export SYMFONY__ENV__DATABASE_PASSWORD=wallapass