Skip to content

Commit c386432

Browse files
committed
Infrastructure update.
1 parent 963a038 commit c386432

File tree

1 file changed

+16
-11
lines changed

1 file changed

+16
-11
lines changed

Makefile

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,35 @@
1-
WIN_ETH_DRIVER := 'Ethernet adapter Ethernet'
1+
#WIN_ETH_DRIVER := 'Ethernet adapter Ethernet'
22

33
ifdef WIN_ETH_DRIVER
44
WIN_ETH_IP := $(shell ipconfig.exe | grep ${WIN_ETH_DRIVER} -A3 | cut -d':' -f 2 | tail -n1 | sed -e 's/\s*//g')
55
endif
66

7+
DC := cd docker && $(shell command -v docker-compose || echo "docker compose") -p ebics-client-php
8+
79
docker-up u start:
8-
cd docker && docker-compose -p ebics-client-php up -d;
9-
@if [ "$(WIN_ETH_IP)" ]; then cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php sh -c "echo '$(WIN_ETH_IP) host.docker.internal' >> /etc/hosts"; fi
10+
$(DC) up -d;
11+
@if [ "$(WIN_ETH_IP)" ]; then $(DC) exec php-cli-ebics-client-php sh -c "echo '$(WIN_ETH_IP) host.docker.internal' >> /etc/hosts"; fi
1012

1113
docker-down d stop:
12-
cd docker && docker-compose -p ebics-client-php down
14+
$(DC) down
1315

1416
docker-build build:
15-
cd docker && docker-compose -p ebics-client-php build --no-cache
17+
$(DC) build --no-cache
18+
19+
docker-install install:
20+
$(DC) exec php-cli-ebics-client-php composer install
1621

1722
docker-php php:
18-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php /bin/bash
23+
$(DC) exec php-cli-ebics-client-php /bin/bash
1924

2025
check:
21-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php ./vendor/bin/phpcbf
22-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php ./vendor/bin/phpcs
23-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php ./vendor/bin/phpstan --xdebug
24-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php ./vendor/bin/phpunit
26+
$(DC) exec php-cli-ebics-client-php ./vendor/bin/phpcbf
27+
$(DC) exec php-cli-ebics-client-php ./vendor/bin/phpcs
28+
$(DC) exec php-cli-ebics-client-php ./vendor/bin/phpstan --xdebug
29+
$(DC) exec php-cli-ebics-client-php ./vendor/bin/phpunit
2530

2631
credentials-pack:
27-
cd docker && docker-compose -p ebics-client-php exec php-cli-ebics-client-php zip -P $(pwd) -r ./tests/_data.zip ./tests/_data/
32+
$(DC) exec php-cli-ebics-client-php zip -P $(pwd) -r ./tests/_data.zip ./tests/_data/
2833

2934
credentials-unpack:
3035
unzip -P $(pwd) ./tests/_data.zip -d .

0 commit comments

Comments
 (0)