Add database creation on install
This commit is contained in:
parent
accc5ba7ae
commit
b8740f3aaa
|
@ -4,10 +4,13 @@ reset=`tput sgr0`
|
|||
|
||||
build:
|
||||
@docker pull mysql
|
||||
@docker pull phpmyadmin/phpmyadmin
|
||||
@docker pull munkyboy/fakesmtp
|
||||
@docker build -t opensupports-srv . || echo "A${red}An error occurred${reset}"
|
||||
|
||||
install:
|
||||
@docker exec -it opensupports-srv bash -c "cd /var/www/html && composer install" || echo "${red}Please execute 'make run' first${reset}"
|
||||
@docker exec -it opensupports-db bash -c "mysql -u root -e \"CREATE DATABASE IF NOT EXISTS development;\" " || echo "${red}Please execute 'make run' first${reset}"
|
||||
|
||||
run:
|
||||
@docker run -d --name opensupports-db -p 4040:3306 -e MYSQL_ALLOW_EMPTY_PASSWORD=yes -v $(PWD)/.dbdata/:/var/lib/mysql mysql
|
||||
|
|
Loading…
Reference in New Issue