Default installation still visible even after deleting the installation folder - php

please, when I want to run exist prestashop project (1.6.1.7) on docker, still showing me page of installation, but I have own DB. Where is a problem? Please, can you help me?
On stackoverflow I didn't found same question, which would help me.
This is my docker-compose.yml
version: "3.8"
services:
prestashop:
image: prestashop/prestashop
ports:
- 82:80
links:
- mysql:mysql
depends_on:
- mysql
volumes:
- ./../:/srv
- ./../modules:/srv/modules
- ./../themes:/srv/themes
- ./../override:/srv/override
environment:
- PS_DEV_MODE=1
- DB_SERVER=mysql
- DB_USER=root
- DB_PASSWD={PASSWORD}
- DB_NAME={DB}
- PS_INSTALL_AUTO=0
mysql:
image: mysql
container_name: mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: {PASSWORD}
MYSQL_DATABASE: {DB}
MYSQL_USER: db_write
MYSQL_PASSWORD: 123
volumes:
- ./data/db/:/var/lib/mysql:delegated
adminer:
image: adminer
container_name: Adminer
restart: always
environment:
ADMINER_DEFAULT_SERVER: mysql
ports:
- 8080:8080
When I go to install my DB is removed which I don't want. I already tried to install the new database and then replace it with my database, but it didn't help.

Related

Docker - Waiting for mysql server

I am trying to run a Shopware Image locally. When I execute the init.sh file from the dnhsoft repo the command stucks at
Waiting for mysql server...
I already tried different images. It just wont work for me.
I used this docker-compose.yml:
version: "2"
services:
shop:
image: dnhsoft/shopware:5.6.9
links:
- mysql:db
- mailhog
ports:
- "8000:80"
volumes:
- "./../mtsTheme:/shopware/themes/Frontend/mtsTheme"
- "./../Local:/shopware/engine/Shopware/Plugins/Local"
mysql:
image: mysql:5.7
ports:
- "3306"
volumes:
## this makes the mysql shopware friendly, otherwise we have some utf8 issues
# - "./docker/mysql/mysqld_charset.cnf:/etc/mysql/conf.d/mysqld_charset.cnf"
- "./volumes/mysql:/var/lib/mysql"
environment:
MYSQL_ROOT_PASSWORD: 123456
TZ: Europe/Berlin
pma:
image: phpmyadmin/phpmyadmin:4.8
links:
- mysql:db
ports:
- "8001:80"
environment:
PMA_USER: root
PMA_PASSWORD: 123456
TZ: Europe/Berlin
mailhog:
image: mailhog/mailhog
expose:
- "1025"
- "8025"
ports:
- "8025:8025"
environment:
TZ: Europe/Berlin

Dockerization PHP-APACHE MYSQL on centos7

i have tried creating a docker container on centos7 but
i could access phpmyadmin page but not index.php page
could you see the docker yml and docker file and tell what happened
like im running through kali linux to a centos7 docker its been difficult i have been trying since yesterday
the give code is docker-compose.yml
version: "3"
services:
www:
build: .
ports:
- "8001:80"
volumes:
- ./www:/var/www/html/
links:
- db
networks:
- default
db:
image: mysql:8.0.16
command: ['--character-set-server=utf8mb4', '--collation-server=utf8mb4_unicode_ci','--default-authentication-plugin=mysql_native_password']
ports:
- "8002:3306"
environment:
MYSQL_DATABASE: myDb
MYSQL_USER: user
MYSQL_PASSWORD: test
MYSQL_ROOT_PASSWORD: test
volumes:
- ./dump:/docker-entrypoint-initdb.d
- persistent:/var/lib/mysql
networks:
- default
phpmyadmin:
image: phpmyadmin/phpmyadmin:4.9
links:
- db:db
ports:
- 8000:80
environment:
MYSQL_USER: user
MYSQL_PASSWORD: test
MYSQL_ROOT_PASSWORD: test
volumes:
persistent:
and the dockerfile
FROM php:7.1.19-apache
RUN docker-php-ext-install mysqli mbstring
i dont know what is the issue like when access localhost:8000 on browser
im getting forbidden access 403 error
i just need to access index.php when i enter localhost:8000 on browser
please help me out,
thank you in advance

Docker - laradoc couldn't get logged in phpmyadmin

I have installed laradoc as per documentation but I am unable to login phpmyadmin.
here is my docker-compose.yaml file:
phpmyadmin:
build: ./phpmyadmin
environment:
- PMA_ARBITRARY=1
- MYSQL_USER=${PMA_USER}
- MYSQL_PASSWORD=${PMA_PASSWORD}
- MYSQL_ROOT_PASSWORD=${PMA_ROOT_PASSWORD}
ports:
- "${PMA_PORT}:80"
depends_on:
- "${PMA_DB_ENGINE}"
networks:
- frontend
- backend
and here is .env file
PMA_DB_ENGINE=mysql
PMA_USER=default
PMA_PASSWORD=secret
PMA_ROOT_PASSWORD=secret
PMA_PORT=8080
Difficult to reproduce the error from the given info but this small setup works so maybe you can find what went wrong?
First bring your existing stack down and delete dangling volumes:
$ docker-compose down
$ docker volume prune
Start the following docker-compose.yaml:
version: '3.1'
services:
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
- PMA_ARBITRARY=1
- MYSQL_USER=${PMA_USER}
- MYSQL_PASSWORD=${PMA_PASSWORD}
- MYSQL_ROOT_PASSWORD=${PMA_ROOT_PASSWORD}
ports:
- "${PMA_PORT}:80"
depends_on:
- "${PMA_DB_ENGINE}"
networks:
- frontend
- backend
mysql:
image: mysql:5.7
environment:
MYSQL_ROOT_PASSWORD: secret
MYSQL_DATABASE: db
MYSQL_USER: default
MYSQL_PASSWORD: secret
networks:
- frontend
- backend
networks:
frontend:
backend:
info (I had to use mysql5.7 otherwise I was facing this bug:
docker-compose up -d
Creating network "test_frontend" with the default driver
Creating network "test_backend" with the default driver
Creating test_mysql_1 ... done
Creating test_phpmyadmin_1 ... done
I know I'm a bit 'messing' with the syntax + you can use the env vars too for mysql but I had to be quick.

Unable to connect phpmyadmin to database using docker compose

May be this question asked few times before but I did't get a valid answer which can solve my problem.
I am trying to run phpmyadmin in docker on different container using docker-compose but It always through the following error:
#2002 - Connection refused — The server is not responding (or the local server's socket is not correctly configured).
My docker compose file contains the following code:
version: "2"
services:
web:
build: .
ports:
- "80:80"
networks:
- web
volumes:
- .:/code
restart: always
db:
image: "mysql:5"
volumes:
- ./mysql:/etc/mysql/conf.d
environment:
MYSQL_ROOT_PASSWORD: toor
MYSQL_DATABASE: phpapp
networks:
- web
restart: always
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
PMA_PORT: 3306
PMA_HOST: db
PMA_USER: root
PMA_PASSWORD: toor
ports:
- "8000:80"
restart: always
networks:
- web
networks:
web:
driver: bridge
In web container I am trying to connect with database and it works fine, but the problem occur with phpmyadmin connection
Any help would be appreciated. :)
Interestng enough, I have your compose-file running and phpmyadmin is accessible
from host.
Had to change port 8000 to 8004 though (port 8000 is occupied on my host).
In case your db-container does not start fast enough for phpmyadmin to connect, I suggest adding depends_on into phpmyadmin service. Makes sure db starts before phpmyadmin.
phpmyadmin:
image: phpmyadmin/phpmyadmin
environment:
PMA_PORT: 3306
PMA_HOST: db
PMA_USER: root
PMA_PASSWORD: toor
ports:
- "8004:80"
restart: always
depends_on:
- db
networks:
- web
Please show logs from docker-compose up if problem persists.
Now you need to add command to mysql service for connecting to phpmyadmin.
command: --default-authentication-plugin=mysql_native_password
version: "2"
services:
db:
image: mysql:latest
command: --default-authentication-plugin=mysql_native_password
ports:
- "3306:3306"
environment:
MYSQL_DATABASE: drupal
MYSQL_USER: user
MYSQL_PASSWORD: test
MYSQL_ROOT_PASSWORD: test
volumes:
- ./dump:/docker-entrypoint-initdb.d
- /var/lib/mysql
networks:
- default
phpmyadmin:
image: phpmyadmin/phpmyadmin
links:
- db:db
ports:
- 8000:80
environment:
PMA_HOST: db
MYSQL_USER: user
MYSQL_PASSWORD: test
MYSQL_ROOT_PASSWORD: test

Problems PHP MARIADB PHPMYADMIN using docker-compose

I've been this last two weeks searching how to link my phpmyadmin and my database, to create a PHP development workspace, through docker-compose but I am not able to connect to the database through the phpmyadmin port.
version: '3'
services:
servicio_php:
image: php:7.3-rc-apache
volumes:
- ./web/:/var/www/html
expose:
- "80"
ports:
- "80:80"
links:
- db
db:
image: mariadb:latest
restart: always
volumes:
- ./Volumenes/mysql:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: root123
MYSQL_USER: user
MYSQL_PASSWORD: user123
MYSQL_DATABASE: bbdd1
expose:
- "3306"
ports:
- "3306:3306"
phpmyadmin:
image: phpmyadmin/phpmyadmin:latest
container_name: phpmyadmin
environment:
PMA_ARBITRARY: 1
MYSQL_ROOT_PASSWORD: root123
MYSQL_USERNAME: user
PMA_HOST: db
MYSQL_PASSWORD: user123
restart: always
ports:
- "8080:80"
volumes:
- ./sessions:/sessions/
depends_on:
- db
links:
- db
I am using windows 10 version of dockers 18.06.1-ce and also when i run docker-compose up i see there are some probles with Innodb but ive read is not a problem.
I am not able to see whats wrong and probably I am not the only one with this problem.

Categories