Compare commits

...

2 Commits

Author SHA1 Message Date
idevakk
66b5d2f89e docs: move MailOps webhook handover document to the docs directory 2026-02-28 23:38:18 +05:30
idevakk
a04222dcf3 fix: restore missing Dockerfile 2026-02-28 23:38:00 +05:30
2 changed files with 62 additions and 0 deletions

62
Dockerfile Normal file
View File

@@ -0,0 +1,62 @@
FROM php:8.4-fpm
# Install system dependencies
RUN apt-get update && apt-get install -y \
git \
curl \
libpng-dev \
libonig-dev \
libxml2-dev \
zip \
unzip \
nginx \
supervisor \
libc-client-dev \
libkrb5-dev \
&& rm -rf /var/lib/apt/lists/*
# Configure and install PHP extensions
RUN docker-php-ext-configure imap --with-kerberos --with-imap-ssl \
&& docker-php-ext-install pdo_mysql mbstring exif pcntl bcmath gd intl imap \
&& pecl install redis \
&& docker-php-ext-enable redis
# Install Composer
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer
# Set working directory
WORKDIR /var/www
# Copy existing application directory contents
COPY . /var/www
# Install PHP dependencies
RUN composer install --no-interaction --no-dev --optimize-autoloader
# Nginx config
COPY .docker/nginx.conf /etc/nginx/sites-available/default
RUN rm -rf /etc/nginx/sites-enabled/default && ln -s /etc/nginx/sites-available/default /etc/nginx/sites-enabled/default
# Supervisor config
COPY .docker/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
# Set directory permissions
RUN chown -R www-data:www-data /var/www/storage /var/www/bootstrap/cache \
&& chmod -R 775 /var/www/storage /var/www/bootstrap/cache
# Build frontend assets
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
&& apt-get install -y nodejs \
&& npm install \
&& npm run build \
&& apt-get remove -y nodejs \
&& apt-get autoremove -y
EXPOSE 80
# Configure entrypoint
COPY .docker/entrypoint.sh /usr/local/bin/entrypoint.sh
RUN chmod +x /usr/local/bin/entrypoint.sh
# Start Supervisor
CMD ["/usr/local/bin/entrypoint.sh"]