Fix redirect path + add Dockerfile

This commit is contained in:
Athallah Ghathfan Aqila
2026-06-11 14:58:53 +07:00
parent 0f1c4e50a0
commit 15d823eb2a
2 changed files with 22 additions and 1 deletions
+21
View File
@@ -0,0 +1,21 @@
FROM php:8.2-apache
RUN apt-get update && apt-get install -y \
libzip-dev zip unzip \
&& docker-php-ext-install mysqli zip \
&& a2enmod rewrite \
&& rm -rf /var/lib/apt/lists/*
COPY --from=composer:2 /usr/bin/composer /usr/bin/composer
WORKDIR /var/www/html
COPY . .
RUN composer install --no-dev --optimize-autoloader --no-interaction
RUN chown -R www-data:www-data /var/www/html \
&& chmod -R 755 /var/www/html \
&& mkdir -p uploads/bukti uploads/kemiskinan \
&& chown -R www-data:www-data uploads/
EXPOSE 80
+1 -1
View File
@@ -8,7 +8,7 @@ function requireLogin() {
echo json_encode(['status' => 'error', 'message' => 'Sesi habis, silakan login kembali.']); echo json_encode(['status' => 'error', 'message' => 'Sesi habis, silakan login kembali.']);
exit; exit;
} }
header('Location: /webgus_lama/uas/login.php'); header('Location: /login.php');
exit; exit;
} }
} }