Skip to content

Commit 0f85dbd

Browse files
authored
Merge pull request #1 from RunOpenCode/feature/switch-to-new-api
Updated library to use new API
2 parents c1a5870 + 6424041 commit 0f85dbd

20 files changed

+509
-2724
lines changed

Dockerfile

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
FROM php:7.4-fpm
2+
3+
RUN apt-get update
4+
RUN apt-get install -y --no-install-recommends wget
5+
RUN apt-get install -y --allow-unauthenticated gnupg
6+
RUN apt-get install -y --allow-unauthenticated xsltproc
7+
RUN apt-get install -y --allow-unauthenticated git
8+
RUN apt-get install -y --allow-unauthenticated zip
9+
RUN apt-get install -y --allow-unauthenticated unzip
10+
RUN apt-get install -y --allow-unauthenticated libzip-dev
11+
12+
#####################################################################################
13+
# #
14+
# Setup Composer #
15+
# #
16+
#####################################################################################
17+
18+
WORKDIR /tmp
19+
20+
ENV COMPOSER_HOME /composer
21+
22+
# Add global binary directory to PATH and make sure to re-export it
23+
ENV PATH /composer/vendor/bin:$PATH
24+
25+
# Allow Composer to be run as root
26+
ENV COMPOSER_ALLOW_SUPERUSER 1
27+
28+
# Setup the Composer installer
29+
RUN curl -o /tmp/composer-setup.php https://getcomposer.org/installer \
30+
&& curl -o /tmp/composer-setup.sig https://composer.github.io/installer.sig \
31+
&& php -r "if (hash('SHA384', file_get_contents('/tmp/composer-setup.php')) !== trim(file_get_contents('/tmp/composer-setup.sig'))) { unlink('/tmp/composer-setup.php'); echo 'Invalid installer' . PHP_EOL; exit(1); }"
32+
33+
RUN php /tmp/composer-setup.php
34+
35+
RUN mv /tmp/composer.phar /usr/local/bin/composer.phar && \
36+
ln -s /usr/local/bin/composer.phar /usr/local/bin/composer && \
37+
chmod +x /usr/local/bin/composer

bin/attach.sh

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/usr/bin/env bash
2+
3+
docker exec -w "/var/www/html" -it runopencode_exchange_rate_intesa_rs_test sh -c "/bin/bash"

bin/run.sh

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
docker-compose up -d --build > /dev/null

bin/shutdown.sh

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
docker-compose down

composer.json

+7-4
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@
3232
"require": {
3333
"php": ">=7.0",
3434
"psr/log": "1.*",
35-
"guzzlehttp/guzzle": "~6.0",
36-
"symfony/dom-crawler": "~2.8|~3.0",
37-
"symfony/css-selector": "~2.8|~3.0",
35+
"guzzlehttp/guzzle": "^6.3",
3836
"runopencode/exchange-rate": "~3.0",
3937
"roave/security-advisories": "dev-master"
4038
},
@@ -47,9 +45,14 @@
4745
"phpmd/phpmd" : "@stable",
4846
"sebastian/phpcpd": "dev-master",
4947
"theseer/phpdox": "dev-master",
50-
"escapestudios/symfony2-coding-standard": "~2.0"
48+
"escapestudios/symfony2-coding-standard": "~2.0",
49+
"phpstan/phpstan": "^1.10"
5150
},
5251
"suggest": {
5352
"runopencode/exchange-rate-bundle": "Exchange rate Symfony bundle."
53+
},
54+
"scripts": {
55+
"phpunit": "vendor/bin/phpunit",
56+
"phpstan": "vendor/bin/phpstan analyse -l 9 src test"
5457
}
5558
}

0 commit comments

Comments
 (0)