Skip to content

Commit bad44c1

Browse files
committed
fastbill#41 - update docker scripts, remove psh with MakeFile
1 parent 47b0087 commit bad44c1

21 files changed

+85
-314
lines changed

Makefile

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
MAKEFLAGS += --warn-undefined-variables
2+
MAKEFLAGS += --no-builtin-rules
3+
4+
.PHONY: help
5+
.PHONY: help
6+
help: ## Shows the help
7+
help:
8+
@printf "\033[33mUsage:\033[0m\n make TARGET\n\n\033[32m#\n# Commands\n#---------------------------------------------------------------------------\033[0m\n"
9+
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//' | awk 'BEGIN {FS = ":"}; {printf "\033[33m%s:\033[0m%s\n", $$1, $$2}'
10+
11+
12+
.PHONY: docker-up
13+
docker-up: ## build the configurator-ram-service and start it
14+
docker-up:
15+
docker compose up
16+
17+
.PHONY: docker-ssh
18+
docker-ssh: ## creates an ssh connection to the configurator-ram-service
19+
docker-ssh:
20+
docker-compose exec sdk bash -l
21+
22+
.PHONY: docker init
23+
import: ## import and initialize the data into the docker container
24+
import:
25+
docker cp ./ fastbill_sdk:/var/www/html/public
26+
docker exec fastbill_sdk bash -c "sudo chown www-data:www-data /var/www -R"
27+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && composer install"
28+
29+
30+
31+
.PHONY: docker-quality
32+
docker-quality: ## executes all quality scripts in the running docker container
33+
docker-quality:
34+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && PHP_CS_FIXER_IGNORE_ENV=true ./tools/php-cs-fixer fix --config=.php-cs-fixer.php"
35+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && ./tools/phpstan analyse -l 5 ./src/"
36+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && ./vendor/bin/phpunit --stop-on-failure --stop-on-error --coverage-html=./build/artifacts/html-coverage"
37+
38+
39+
.PHONY: docker-cs
40+
docker-cs: ## executes code style scripts in the running docker container
41+
docker-cs:
42+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && PHP_CS_FIXER_IGNORE_ENV=true ./tools/php-cs-fixer fix --config=.php-cs-fixer.php"
43+
44+
.PHONY: docker-phpstan
45+
docker-phpstan: ## executes phpstan scripts in the running docker container
46+
docker-phpstan:
47+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && ./tools/phpstan analyse -l 5 ./src/"
48+
49+
.PHONY: docker-unit
50+
docker-unit: ## executes php unit in the running docker container
51+
docker-unit:
52+
docker exec fastbill_sdk bash -c "cd /var/www/html/public && ./vendor/bin/phpunit --stop-on-failure --stop-on-error --coverage-html=./build/artifacts/html-coverage"
53+
54+
55+

dev-ops/common/actions/code-style.sh

Lines changed: 0 additions & 4 deletions
This file was deleted.

dev-ops/common/actions/quality.sh

Lines changed: 0 additions & 4 deletions
This file was deleted.

dev-ops/common/actions/unit.sh

Lines changed: 0 additions & 4 deletions
This file was deleted.

dev-ops/docker/_volumes/.gitkeep

Whitespace-only changes.

dev-ops/docker/actions/destroy.sh

Lines changed: 0 additions & 6 deletions
This file was deleted.

dev-ops/docker/actions/ssh.sh

Lines changed: 0 additions & 3 deletions
This file was deleted.

dev-ops/docker/actions/start.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

dev-ops/docker/actions/status.sh

Lines changed: 0 additions & 6 deletions
This file was deleted.

dev-ops/docker/actions/stop.sh

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)