Added docker compose for consistent MySQL setup
This commit is contained in:
18
docker-compose.yml
Normal file
18
docker-compose.yml
Normal file
@@ -0,0 +1,18 @@
|
||||
services:
|
||||
mysql:
|
||||
image: mysql:8.4
|
||||
container_name: petstore-mysql
|
||||
ports:
|
||||
- "3306:3306"
|
||||
environment:
|
||||
MYSQL_ROOT_PASSWORD: rootpass
|
||||
MYSQL_DATABASE: Petstoredb
|
||||
MYSQL_USER: petapp
|
||||
MYSQL_PASSWORD: petapppass
|
||||
volumes:
|
||||
- ./Petstoredata.sql:/docker-entrypoint-initdb.d/01-Petstoredata.sql:ro
|
||||
- petstore_mysql_data:/var/lib/mysql
|
||||
|
||||
volumes:
|
||||
petstore_mysql_data:
|
||||
|
||||
Reference in New Issue
Block a user