From 9e5f192dda8d51e2ec98741107f7a83af4e5ff33 Mon Sep 17 00:00:00 2001 From: marko Date: Sun, 21 Jul 2024 16:49:30 +0200 Subject: [PATCH] WIP: connection to db possible --- homepage/cwsvJudo/participo/docker-compose.yml | 11 +++++------ homepage/cwsvJudo/participo/nginx.conf | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/homepage/cwsvJudo/participo/docker-compose.yml b/homepage/cwsvJudo/participo/docker-compose.yml index 7af6a08..b251610 100644 --- a/homepage/cwsvJudo/participo/docker-compose.yml +++ b/homepage/cwsvJudo/participo/docker-compose.yml @@ -11,10 +11,11 @@ services: # forward port 80 top port 80 in the container - "80:80" # files and directories to be available in the container - volumes: + # - localPath:pathInContainer + volumes: - ./nginx.conf:/etc/nginx/conf.d/nginx.conf # - ./app:/app - - .cwsvjudo:/users/cwsvjudo/ + - ./cwsvjudo@bplaced/:/users/cwsvjudo # php and extensions php: # use pre-build image from docker.. @@ -26,7 +27,7 @@ services: # files and directories to be available in the container # @todo Except from better structuring: Is there a reason for not having the volumes as one central list? volumes: - - ./app:/app + - ./cwsvjudo@bplaced:/users/cwsvjudo/ # install a dm # @todo Maybe use postgre instead? database: @@ -37,7 +38,6 @@ services: environment: MYSQL_USER: 'cwsvjudo' MYSQL_DATABASE: 'cwsvjudo' - MYSQL_TCP_PORT: '3306' MYSQL_ROOT_PASSWORD_FILE: /run/secrets/db_root_password MYSQL_PASSWORD_FILE: /run/secrets/db_password volumes: @@ -45,8 +45,7 @@ services: # initial database # - has to be created first, e.g., by dumping the database from the prooductive system - ./cwsvjudo.sql:/docker-entrypoint-initdb.d/cwsvjudo.sql - ports: - - 3306:3306 + secrets: - db_root_password - db_password diff --git a/homepage/cwsvJudo/participo/nginx.conf b/homepage/cwsvJudo/participo/nginx.conf index c21573c..e8dbdd0 100644 --- a/homepage/cwsvJudo/participo/nginx.conf +++ b/homepage/cwsvJudo/participo/nginx.conf @@ -1,7 +1,7 @@ # @todo Needs helpfull comments. server { listen 80 default_server; - root /cwsvjudo/www; + root /users/cwsvjudo/www; index index.php index.html index.htm;