dockware
Search…
Dockware and other images
Can I use dockware in combination with other images?
Dockware is a Docker image like every other image. You can combine it with 3rd party services such as Redis, Elasticsearch, a separate MySQL, Percona or anything else.
Make sure they are on the same Docker network and use the key names of the containers as host addresses.
Here's an example:
docker-compose.yml
1
version: "3"
2
3
services:
4
5
shopware:
6
image: dockware/play:latest
7
container_name: shopware
8
ports:
9
- "80:80"
10
networks:
11
- web
12
13
db:
14
image: mysql:5.7
15
container_name: mysql
16
networks:
17
- web
18
environment:
19
- MYSQL_ROOT_PASSWORD=hidden
20
- MYSQL_USER=shopuser
21
- MYSQL_PASSWORD=secret
22
- MYSQL_DATABASE=shopware
23
24
networks:
25
web:
26
external: false
Copied!
To access the standalone MySQL instance you need to set the correct host.
The host is the name of your container (here -> "db")
Different systems have different options to configure a database connection string. In Shopware 6, it would be inside the .env file as DATABASE_URL. In Shopware 5, it is in the config.php file.
SHOPWARE 6 (.env file inside docker)
1
DATABASE_URL=mysql://shopuser:[email protected]:3306/shopware
Copied!
Last modified 2mo ago
Copy link