feat : add dockerfile

This commit is contained in:
2026-06-10 22:29:23 +07:00
parent a6acb10ffe
commit 89343d72af
3 changed files with 30 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
# 1. Menggunakan base image PHP resmi yang sudah dilengkapi server web Apache
FROM php:8.1-apache
# 2. Menginstall dan mengaktifkan ekstensi mysqli untuk koneksi database MySQL/MariaDB
RUN docker-php-ext-install mysqli && docker-php-ext-enable mysqli
# 3. Menyalin seluruh source code aplikasi dari lokal ke direktori dokumen web Apache di dalam container
COPY . /var/www/html/
# 4. Mengatur hak akses (permissions) folder web agar server Apache dapat membaca file dengan lancar
RUN chown -R www-data:www-data /var/www/html \
&& chmod -R 755 /var/www/html
# 5. Membuka port 80 untuk akses browser ke WebGIS
EXPOSE 80
+15
View File
@@ -0,0 +1,15 @@
# 1. Menggunakan base image PHP resmi yang sudah dilengkapi server web Apache
FROM php:8.1-apache
# 2. Menginstall dan mengaktifkan ekstensi mysqli untuk koneksi database MySQL/MariaDB
RUN docker-php-ext-install mysqli && docker-php-ext-enable mysqli
# 3. Menyalin seluruh source code aplikasi dari lokal ke direktori dokumen web Apache di dalam container
COPY . /var/www/html/
# 4. Mengatur hak akses (permissions) folder web agar server Apache dapat membaca file dengan lancar
RUN chown -R www-data:www-data /var/www/html \
&& chmod -R 755 /var/www/html
# 5. Membuka port 80 untuk akses browser ke WebGIS
EXPOSE 80
View File