commit 4078a4f1c469b5bf97b590453fa8e016615ad258 Author: wander Date: Tue May 26 12:26:20 2026 -0300 Enviar arquivos para "/" diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..4cca42b --- /dev/null +++ b/Dockerfile @@ -0,0 +1,29 @@ +FROM php:8.1-apache + +RUN apt-get update && apt-get install -y \ + libpng-dev \ + libjpeg-dev \ + libfreetype6-dev \ + libzip-dev \ + unzip \ + tar \ + && docker-php-ext-configure gd --with-freetype --with-jpeg \ + && docker-php-ext-install mysqli pdo pdo_mysql gd zip \ + && a2enmod rewrite headers \ + && rm -rf /var/lib/apt/lists/* + +# Copia os arquivos do projeto +COPY . /var/www/html/ + +# Descompacta app.tar.gz na própria pasta do projeto +RUN if [ -f /var/www/html/app.tar.gz ]; then \ + tar -xzf /var/www/html/app.tar.gz -C /var/www/html && \ + rm -f /var/www/html/app.tar.gz; \ + fi + +# Permissões +RUN chown -R www-data:www-data /var/www/html \ + && find /var/www/html -type d -exec chmod 755 {} \; \ + && find /var/www/html -type f -exec chmod 644 {} \; + +EXPOSE 80 \ No newline at end of file diff --git a/app.tar.gz b/app.tar.gz new file mode 100644 index 0000000..8bd8e07 Binary files /dev/null and b/app.tar.gz differ