forked from limosa-io/laravel-openid-connect-server
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
30 lines (20 loc) · 1.03 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM php:7.4-alpine
RUN apk add --no-cache git jq moreutils yarn
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
RUN composer create-project --prefer-dist laravel/laravel example && cd example
WORKDIR /example
RUN composer require moontoast/math laravel/ui
RUN cd /src; php artisan ui vue --auth && \
yarn install && \
yarn production
COPY . /laravel-openid-connect
RUN jq '.repositories=[{"type": "path","url": "/laravel-openid-connect"}]' ./composer.json | sponge ./composer.json
RUN composer require nl.idaas/laravel-openid-connect @dev
RUN touch ./.database.sqlite && \
echo "DB_CONNECTION=sqlite" >> ./.env && \
echo "DB_DATABASE=/example/.database.sqlite" >> ./.env
RUN php artisan migrate
RUN php artisan passport:install
RUN php artisan vendor:publish --provider="Idaas\Passport\PassportServiceProvider" --force
# php artisan passport:client --user_id=0 --name=op-test --redirect_uri=https://op-test:60001/authz_cb
CMD php artisan serve --host=0.0.0.0 --port=8000