ubah ke docker mode
This commit is contained in:
No files matched your search
@@ -0,0 +1,46 @@
|
|||||||
|
services:
|
||||||
|
# NginxProxyManager
|
||||||
|
#---------------------------------------------------------------#
|
||||||
|
# Authentik Database
|
||||||
|
postgresql:
|
||||||
|
image: docker.io/library/postgres:12-alpine
|
||||||
|
mem_limit: 1g
|
||||||
|
cpus: 1.0
|
||||||
|
container_name: laravel-db
|
||||||
|
restart: unless-stopped
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}"]
|
||||||
|
start_period: 20s
|
||||||
|
interval: 30s
|
||||||
|
retries: 5
|
||||||
|
timeout: 5s
|
||||||
|
volumes:
|
||||||
|
- ./authentik/database:/var/lib/postgresql/data
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD: ${PG_PASS:?database password required}
|
||||||
|
POSTGRES_USER: ${PG_USER:-authentik}
|
||||||
|
POSTGRES_DB: ${PG_DB:-authentik}
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
networks:
|
||||||
|
- proxy
|
||||||
|
|
||||||
|
laravel:
|
||||||
|
build:
|
||||||
|
context: ./htdocs
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
container_name: laravel
|
||||||
|
restart: unless-stopped
|
||||||
|
volumes:
|
||||||
|
- ./htdocs:/var/www/html
|
||||||
|
ports:
|
||||||
|
- "8088:8080"
|
||||||
|
depends_on:
|
||||||
|
- laravel-db
|
||||||
|
command: php artisan serve --host=0.0.0.0 --port=8080
|
||||||
|
networks:
|
||||||
|
- proxy
|
||||||
|
|
||||||
|
networks:
|
||||||
|
proxy:
|
||||||
|
external: true
|
||||||
@@ -0,0 +1,66 @@
|
|||||||
|
FROM php:8.3-fpm
|
||||||
|
|
||||||
|
# Install system dependencies
|
||||||
|
RUN apt-get update && apt-get install -y \
|
||||||
|
pkg-config \
|
||||||
|
libzip-dev \
|
||||||
|
libpng-dev \
|
||||||
|
libjpeg-dev \
|
||||||
|
libonig-dev \
|
||||||
|
libxml2-dev \
|
||||||
|
libxslt-dev \
|
||||||
|
libmagickwand-dev \
|
||||||
|
libreadline-dev \
|
||||||
|
libsodium-dev \
|
||||||
|
libc-client-dev \
|
||||||
|
libkrb5-dev \
|
||||||
|
unzip \
|
||||||
|
git \
|
||||||
|
curl \
|
||||||
|
zip \
|
||||||
|
build-essential \
|
||||||
|
autoconf \
|
||||||
|
libtool \
|
||||||
|
libsqlite3-dev \
|
||||||
|
mariadb-client \
|
||||||
|
&& docker-php-ext-configure imap --with-kerberos --with-imap-ssl \
|
||||||
|
&& docker-php-ext-install \
|
||||||
|
dom \
|
||||||
|
xml \
|
||||||
|
xsl \
|
||||||
|
bcmath \
|
||||||
|
calendar \
|
||||||
|
exif \
|
||||||
|
ftp \
|
||||||
|
gd \
|
||||||
|
gettext \
|
||||||
|
mbstring \
|
||||||
|
pcntl \
|
||||||
|
pdo_mysql \
|
||||||
|
pdo_sqlite \
|
||||||
|
posix \
|
||||||
|
shmop \
|
||||||
|
simplexml \
|
||||||
|
sockets \
|
||||||
|
sodium \
|
||||||
|
zip \
|
||||||
|
imap \
|
||||||
|
xmlwriter \
|
||||||
|
&& pecl install imagick \
|
||||||
|
&& docker-php-ext-enable imagick \
|
||||||
|
&& apt-get purge -y --auto-remove \
|
||||||
|
&& apt-get clean \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Install Composer
|
||||||
|
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
|
||||||
|
|
||||||
|
WORKDIR /var/www/html
|
||||||
|
# Install Laravel 10.10 secara langsung (opsional jika project belum ada)
|
||||||
|
# RUN composer create-project laravel/laravel:^10 /var/www/html
|
||||||
|
|
||||||
|
# Set permission
|
||||||
|
RUN chown -R www-data:www-data /var/www/html/storage /var/www/html/bootstrap/cache
|
||||||
|
|
||||||
|
EXPOSE 9000
|
||||||
|
CMD ["php-fpm"]
|
||||||
Loaded 100 of 15161 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in New Issue
Block a user