I fucked up :3
This commit is contained in:
6
.idea/vcs.xml
generated
Normal file
6
.idea/vcs.xml
generated
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||
</component>
|
||||
</project>
|
||||
@@ -1,18 +1,13 @@
|
||||
FROM php:8.3-apache
|
||||
|
||||
# Enable mod_rewrite for clean URLs
|
||||
RUN a2enmod rewrite
|
||||
|
||||
# Install PHP extensions
|
||||
RUN docker-php-ext-install pdo_mysql
|
||||
|
||||
# Copy Apache vhost config
|
||||
COPY docker/apache.conf /etc/apache2/sites-available/000-default.conf
|
||||
|
||||
# Copy all project files into the container
|
||||
COPY . /var/www/html
|
||||
|
||||
# Fix permissions
|
||||
RUN chown -R www-data:www-data /var/www/html
|
||||
|
||||
WORKDIR /var/www/html
|
||||
@@ -5,7 +5,7 @@ services:
|
||||
ports:
|
||||
- "8080:80"
|
||||
volumes:
|
||||
- ".:/var/www/html" # whole project, not just src/
|
||||
- ".:/var/www/html"
|
||||
environment:
|
||||
- DB_HOST=${DB_HOST}
|
||||
- DB_NAME=${DB_NAME}
|
||||
|
||||
@@ -2,8 +2,6 @@
|
||||
|
||||
namespace src;
|
||||
|
||||
use http\Exception\RuntimeException;
|
||||
|
||||
class View
|
||||
{
|
||||
|
||||
|
||||
@@ -6,6 +6,6 @@ class HomeData
|
||||
{
|
||||
public function __construct(
|
||||
public string $pageTitle,
|
||||
public array $posts // Or even better: public array|PostDTO[] $posts
|
||||
public array $posts
|
||||
) {}
|
||||
}
|
||||
Reference in New Issue
Block a user