Files

36 lines
744 B
Docker
Raw Permalink Normal View History

FROM php:8.5-cli
# Install system dependencies
RUN apt-get update && apt-get install -y \
unzip \
git \
libzip-dev \
libpng-dev \
curl \
&& rm -rf /var/lib/apt/lists/*
# Install PHP extensions
RUN docker-php-ext-install zip pdo pdo_mysql bcmath pcntl
# Install Composer
COPY --from=composer:latest /usr/bin/composer /usr/local/bin/composer
# Set working directory
WORKDIR /app
# Copy composer files and necessary directories first
COPY composer.json composer.lock* ./
COPY config ./config/
# Install dependencies
RUN composer install --no-interaction --optimize-autoloader
# Copy remaining application files
COPY . .
# Expose port
EXPOSE 8787
# Start webman in foreground mode
CMD ["php", "start.php", "start"]