Skip to content

Commit c3240c0

Browse files
committed
Remove MySQL parts
1 parent 7c25f70 commit c3240c0

File tree

6 files changed

+7
-56
lines changed

6 files changed

+7
-56
lines changed

.env

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ APP_SECRET=67d829bf61dc5f87a73fd814e2c9f629
1111
###> doctrine/doctrine-bundle ###
1212
# Format described at http://docs.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url
1313
# For a MySQL database, use: "mysql://db_user:[email protected]:3306/db_name"
14-
# If you want to use Docker MySQL, use: "mysql://symfony-demo:symfony-demo@db:3306/symfony-demo"
1514
# Configure your db driver and server_version in config/packages/doctrine.yaml
1615
DATABASE_URL=sqlite:///%kernel.project_dir%/data/database.sqlite
1716
###< doctrine/doctrine-bundle ###

Dockerfile

-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ RUN export PHP_CPPFLAGS="${PHP_CPPFLAGS} -std=c++11" \
3838
docker-php-ext-install -j "$(nproc)" \
3939
intl \
4040
pdo \
41-
# pdo_mysql \ Uncomment it to use MySQL, and remove the pdo_sqlite (see: docker-compose.yml, docker-compose.override.yml.dist)
4241
zip \
4342
bcmath \
4443
; \

Makefile

+7-15
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ PHPCSFIXER?=$(EXEC) php -d memory_limit=1024m vendor/bin/php-cs-fixer
55

66
.DEFAULT_GOAL := help
77
.PHONY: help start stop restart install uninstall reset clear-cache tty clear clean
8-
.PHONY: db-diff db-migrate db-rollback db-reset db-validate wait-for-db
8+
.PHONY: db-diff db-migrate db-rollback db-fixtures db-validate
99
.PHONY: watch assets assets-build
10-
.PHONY: tests lint lint-symfony lint-yaml lint-twig lint-twig php-cs php-cs-fix security-check test-schema test-all
10+
.PHONY: tests lint lint-symfony lint-yaml lint-twig lint-xliff php-cs php-cs-fix security-check test-schema test-all
1111
.PHONY: build up perm
1212
.PHONY: docker-compose.override.yml
1313

@@ -55,27 +55,19 @@ clean: clear
5555
## Database
5656
##---------------------------------------------------------------------------
5757

58-
wait-for-db:
59-
$(EXEC) php -r "set_time_limit(60);for(;;){if(@fsockopen('db',3306)){break;}echo \"Waiting for MySQL\n\";sleep(1);}"
60-
61-
db-diff: vendor wait-for-db ## Generate a migration by comparing your current database to your mapping information
58+
db-diff: vendor ## Generate a migration by comparing your current database to your mapping information
6259
$(EXEC) $(CONSOLE) doctrine:migration:diff
6360

64-
db-migrate: vendor wait-for-db ## Migrate database schema to the latest available version
61+
db-migrate: vendor ## Migrate database schema to the latest available version
6562
$(EXEC) $(CONSOLE) doctrine:migration:migrate -n
6663

67-
db-rollback: vendor wait-for-db ## Rollback the latest executed migration
64+
db-rollback: vendor ## Rollback the latest executed migration
6865
$(EXEC) $(CONSOLE) doctrine:migration:migrate prev -n
6966

70-
db-reset: vendor wait-for-db ## Reset the database
71-
$(EXEC) $(CONSOLE) doctrine:database:drop --force --if-exists
72-
$(EXEC) $(CONSOLE) doctrine:database:create --if-not-exists
73-
$(EXEC) $(CONSOLE) doctrine:migrations:migrate -n
74-
75-
db-fixtures: vendor wait-for-db ## Apply doctrine fixtures
67+
db-fixtures: vendor ## Apply doctrine fixtures
7668
$(EXEC) $(CONSOLE) doctrine:fixtures:load -n
7769

78-
db-validate: vendor wait-for-db ## Check the ORM mapping
70+
db-validate: vendor ## Check the ORM mapping
7971
$(EXEC) $(CONSOLE) doctrine:schema:validate
8072

8173

docker-compose.override.yml.dist

-5
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,3 @@ services:
44
nginx:
55
ports:
66
- 127.0.0.1:8080:80
7-
8-
# Uncomment it, if you want to use MySQL (see: Dockerfile, docker-compose.yml)
9-
# db:
10-
# ports:
11-
# - 127.0.0.1:3306:3306

docker-compose.yml

-26
Original file line numberDiff line numberDiff line change
@@ -16,37 +16,11 @@ services:
1616
build:
1717
context: .
1818
target: app-dev
19-
# Uncomment if you want to use MySQL (see: Dockerfile, docker-compose.override.yml)
20-
# depends_on:
21-
# - db
2219
networks:
2320
- frontend
24-
# Uncomment if you want to use MySQL (see: Dockerfile, docker-compose.override.yml)
25-
# - backend
2621
volumes:
2722
- .:/app
2823

29-
# Uncomment if you want to use MySQL (see: Dockerfile, docker-compose.override.yml)
30-
# db:
31-
# build:
32-
# context: docker
33-
# dockerfile: MysqlDockerfile
34-
# environment:
35-
# - MYSQL_ROOT_PASSWORD=symfony-demo
36-
# - MYSQL_USER=symfony-demo
37-
# - MYSQL_PASSWORD=symfony-demo
38-
# - MYSQL_DATABASE=symfony-demo
39-
# volumes:
40-
# - db_data:/var/lib/mysql
41-
# networks:
42-
# - backend
43-
44-
# Uncomment if you want to use MySQL (see: Dockerfile, docker-compose.override.yml)
45-
#volumes:
46-
# db_data:
47-
# driver: local
4824

4925
networks:
5026
frontend:
51-
# Uncomment if you want to use MySQL (see: Dockerfile, docker-compose.override.yml)
52-
# backend:

docker/MysqlDockerfile

-8
This file was deleted.

0 commit comments

Comments
 (0)