- Issue created by @gillex
- Issue was unassigned.
If you open the browser dev console you will probably see a lot of 404 errors for CSS and JS files. This is probably due to nginx not being set up properly for Drupal. There used to be an "official" nginx configuration on that project's website which I think now is gone. β¨ Provide documentation/default server block for Nginx server. Needs work exists. There, you may find the correct configuration.
so, i use docker for drupal.
this is my dockerfile
```
FROM ubuntu:22.04ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y \
lsb-release \
ca-certificates \
apt-transport-https \
software-properties-common \
&& add-apt-repository ppa:ondrej/php \
&& apt-get updateRUN apt-get install -y \
nginx \
php8.3 \
php8.3-fpm \
php8.3-mysql \
php8.3-gd \
php8.3-xml \
php8.3-curl \
php8.3-mbstring \
php8.3-zip \
php8.3-intl \
tzdata \
wget \
curl \
unzip \
mariadb-client \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*RUN wget -O drupal.tar.gz https://ftp.drupal.org/files/projects/drupal-10.2.7.tar.gz \
&& tar -xzf drupal.tar.gz \
&& rm drupal.tar.gz \
&& mv drupal-10.2.7 /var/www/html/drupalRUN chown -R www-data:www-data /var/www/html/drupal && \
chmod -R 755 /var/www/html/drupalRUN echo 'server { \
listen 80; \
server_name localhost; \
root /var/www/html/drupal; \
index index.php index.html index.htm; \
location / { \
try_files $uri /index.php?$query_string; \
} \
location ~ \.php$ { \
include snippets/fastcgi-php.conf; \
fastcgi_pass unix:/var/run/php/php8.3-fpm.sock; \
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; \
include fastcgi_params; \
} \
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { \
expires max; \
log_not_found off; \
} \
}' > /etc/nginx/sites-available/defaultCMD service php8.3-fpm start && nginx -g 'daemon off;'```
simillar but on drupal 9.x.x is working.
issue in screenshot drupal 2.png
please help me, i don't know how to fix it
I will help you. Use DDEV instead of trying to set up an image yourself.
but i need to use different php and drupal combinations to test the plugin. so i need to constract different versions on docker. can i use ddev for example to drupal and older php versions?
I wonβt paste the documentation here but you could look into https://ddev.readthedocs.io/en/stable/users/configuration/config/#php_ve....
'server { \
listen 80; \
server_name localhost; \
root /var/www/html/drupal; \
index index.php index.html index.htm; \
location / { \
try_files $uri /index.php?$query_string; \
} \
location ~ \.php$ { \
include snippets/fastcgi-php.conf; \
fastcgi_pass unix:/var/run/php/php8.1-fpm.sock; \
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; \
include fastcgi_params; \
} \
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ { \
try_files $uri /index.php?$query_string; \
expires 1y; \
log_not_found off; \
add_header Cache-Control "private,must-revalidate"; \
} \
}' > /etc/nginx/sites-available/default- Status changed to Postponed: needs info
6 months ago 5:38pm 28 July 2024 - Status changed to Closed: outdated
2 months ago 2:54am 15 November 2024