Add simple README and LICENSE files
This commit is contained in:
parent
c4150dc362
commit
8ea48bcaf3
0
LICENSE.md
Normal file
0
LICENSE.md
Normal file
5
api/bin/docker-init.sh
Executable file
5
api/bin/docker-init.sh
Executable file
@ -0,0 +1,5 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
./bin/console doctrine:migrations:migrate --no-interaction
|
||||||
|
|
||||||
|
exec "$@"
|
@ -53,7 +53,7 @@ services:
|
|||||||
|
|
||||||
#proxy configuration
|
#proxy configuration
|
||||||
proxy.locator:
|
proxy.locator:
|
||||||
class: 'ProxyManager\FileLocator\FileLocator'
|
class: 'App\Service\Proxy\FileLocator'
|
||||||
arguments: ['%kernel.cache_dir%/proxy']
|
arguments: ['%kernel.cache_dir%/proxy']
|
||||||
|
|
||||||
proxy.strategy:
|
proxy.strategy:
|
||||||
@ -68,7 +68,6 @@ services:
|
|||||||
|
|
||||||
ProxyManager\Configuration: '@proxy.config'
|
ProxyManager\Configuration: '@proxy.config'
|
||||||
|
|
||||||
|
|
||||||
# converter
|
# converter
|
||||||
App\Service\AggregateConverter:
|
App\Service\AggregateConverter:
|
||||||
arguments:
|
arguments:
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
FROM php:7.4-fpm-alpine
|
FROM php:7.4-fpm-alpine
|
||||||
|
|
||||||
ENV APP_ENV=prod
|
ENV APP_ENV=prod
|
||||||
ENV DATABASE_URL="sqlite:///var/db/app.db"
|
ENV DATABASE_URL="sqlite:////var/db/app.db"
|
||||||
|
ENV PATH=$PATH:/usr/src/app/bin
|
||||||
|
|
||||||
RUN apk add --no-cache autoconf openssl-dev g++ make pcre-dev icu-dev zlib-dev libzip-dev git && \
|
RUN apk add --no-cache autoconf openssl-dev g++ make pcre-dev icu-dev zlib-dev libzip-dev git && \
|
||||||
docker-php-ext-install bcmath intl opcache zip sockets && \
|
docker-php-ext-install bcmath intl opcache zip sockets && \
|
||||||
@ -21,4 +22,4 @@ RUN ln -snf /usr/share/zoneinfo/Europe/Warsaw /etc/localtime &&
|
|||||||
|
|
||||||
WORKDIR /var/www
|
WORKDIR /var/www
|
||||||
|
|
||||||
EXPOSE 9001
|
CMD ["./bin/docker-init.sh", "php-fpm"]
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
FROM php:7.4-alpine
|
FROM php:7.4-alpine
|
||||||
|
|
||||||
ENV APP_ENV=prod
|
ENV APP_ENV=prod
|
||||||
ENV DATABASE_URL="sqlite:///var/db/app.db"
|
ENV DATABASE_URL="sqlite:////var/db/app.db"
|
||||||
|
ENV PATH=$PATH:/usr/src/app/bin
|
||||||
|
|
||||||
RUN apk add --no-cache autoconf openssl-dev g++ make pcre-dev icu-dev zlib-dev libzip-dev git && \
|
RUN apk add --no-cache autoconf openssl-dev g++ make pcre-dev icu-dev zlib-dev libzip-dev git && \
|
||||||
docker-php-ext-install bcmath intl opcache zip sockets && \
|
docker-php-ext-install bcmath intl opcache zip sockets && \
|
||||||
@ -21,4 +22,4 @@ RUN composer dump-autoload --optimize && \
|
|||||||
|
|
||||||
EXPOSE 8080
|
EXPOSE 8080
|
||||||
|
|
||||||
CMD ["rr", "serve"]
|
CMD ["./bin/docker-init.sh", "rr", "serve"]
|
||||||
|
@ -1,10 +1,17 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
|
||||||
namespace App\Service\Proxy;
|
namespace App\Service\Proxy;
|
||||||
|
|
||||||
|
final class FileLocator extends \ProxyManager\FileLocator\FileLocator
|
||||||
class FileLocator
|
|
||||||
{
|
{
|
||||||
|
public function __construct(string $proxiesDirectory)
|
||||||
|
{
|
||||||
|
$absolutePath = realpath($proxiesDirectory);
|
||||||
|
|
||||||
|
if ($absolutePath === false) {
|
||||||
|
mkdir($proxiesDirectory, 0755, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
parent::__construct($proxiesDirectory);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user