@@ -37,8 +37,6 @@ check-app-dir:
37
37
exit 1; \
38
38
fi
39
39
40
- .PHONY : ... db-dump db-restore db-connect php-connect ...
41
-
42
40
help :
43
41
@echo " "
44
42
@echo " ${BLUE} Docker Nginx PHP MySQL - Version 2.0${NC} "
71
69
@echo " ${GREEN} Utility commands:${NC} "
72
70
@echo " ${YELLOW} gen-certs${NC} Generate SSL certificates"
73
71
@echo " ${YELLOW} enable-ssl${NC} Enable SSL in Nginx configuration"
74
- @echo " ${YELLOW} env-clean${NC} Clean environment resources"
75
- @echo " ${YELLOW} env-reset${NC} Reset environment (including volumes)"
76
72
@echo " "
77
73
@echo " ${GREEN} Framework commands:${NC} "
78
74
@echo " ${YELLOW} install-symfony${NC} Install Symfony framework"
@@ -269,16 +265,16 @@ db-connect:
269
265
fi
270
266
271
267
# Utility commands
272
- .PHONY : php-connect gen-certs enable-ssl env-clean env-reset apidoc reset-owner
268
+ .PHONY : php-connect gen-certs enable-ssl apidocs-generate apidocs-serve apidocs reset-owner
273
269
274
270
php-connect :
275
- @echo " ${BLUE} Connexion au shell du conteneur PHP ...${NC} "
271
+ @echo " ${BLUE} Connecting to PHP container shell ...${NC} "
276
272
@if ! $(DOCKER_COMPOSE ) ps --services --filter " status=running" | grep -q $(PHP_CONTAINER ) ; then \
277
- echo " ${YELLOW} Le conteneur PHP n'est pas en cours d'exécution !${NC} " ; \
273
+ echo " ${YELLOW} PHP container is not running !${NC} " ; \
278
274
exit 1; \
279
275
fi
280
276
@$(DOCKER_COMPOSE ) exec -it $(PHP_CONTAINER ) bash
281
- @echo " ${GREEN} Session shell du conteneur PHP terminée .${NC} "
277
+ @echo " ${GREEN} PHP container shell session ended .${NC} "
282
278
283
279
gen-certs :
284
280
@echo " ${BLUE} Generating SSL certificates...${NC} "
@@ -306,39 +302,6 @@ enable-ssl:
306
302
@$(MAKE ) restart
307
303
@echo " ${GREEN} SSL has been enabled. Access your site at https://${NGINX_HOST} :3000${NC} "
308
304
309
- env-clean :
310
- @echo " ${BLUE} Cleaning environment resources...${NC} "
311
- @echo " ${YELLOW} This will remove unused resources related to this project${NC} "
312
- @echo " ${YELLOW} Are you sure you want to continue? [y/N] ${NC} "
313
- @read -r confirmation; \
314
- if [ " $$ confirmation" = " y" ] || [ " $$ confirmation" = " Y" ]; then \
315
- echo " ${BLUE} Removing unused project resources...${NC} " ; \
316
- docker container prune -f --filter " label=com.docker.compose.project=${PROJECT_NAME:- docker_nginx_php_mysql} " ; \
317
- docker network prune -f --filter " label=com.docker.compose.project=${PROJECT_NAME:- docker_nginx_php_mysql} " ; \
318
- rm -rf .phpdoc; \
319
- rm -rf etc/ssl/* ; \
320
- echo " ${GREEN} Environment cleaned!${NC} " ; \
321
- else \
322
- echo " ${BLUE} Operation canceled.${NC} " ; \
323
- fi
324
-
325
- env-reset : stop
326
- @echo " ${YELLOW} WARNING: This will reset the project environment including all volumes and data!${NC} "
327
- @echo " ${YELLOW} Are you sure you want to continue? [y/N] ${NC} "
328
- @read -r confirmation; \
329
- if [ " $$ confirmation" = " y" ] || [ " $$ confirmation" = " Y" ]; then \
330
- echo " ${BLUE} Resetting project environment...${NC} " ; \
331
- docker container prune -f --filter " label=com.docker.compose.project=${PROJECT_NAME:- docker_nginx_php_mysql} " ; \
332
- docker network prune -f --filter " label=com.docker.compose.project=${PROJECT_NAME:- docker_nginx_php_mysql} " ; \
333
- docker volume rm $(shell docker volume ls -q -f name=${PROJECT_NAME:-docker_nginx_php_mysql}) 2> /dev/null || true ; \
334
- rm -rf .phpdoc; \
335
- rm -rf etc/ssl/* ; \
336
- rm -rf $(MYSQL_DUMPS_DIR ) /* ; \
337
- echo " ${GREEN} Environment reset completed!${NC} " ; \
338
- else \
339
- echo " ${BLUE} Operation canceled.${NC} " ; \
340
- fi
341
-
342
305
apidocs-generate :
343
306
@echo " ${BLUE} Generating API documentation for $( APP_DIR) ...${NC} "
344
307
@if [ ! -d " $( APP_ROOT) /src" ]; then \
0 commit comments