Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect content-type header for XSL files in nginx-fpm image #5457

Closed
1 task done
apotek opened this issue Oct 24, 2023 · 13 comments · Fixed by #5458
Closed
1 task done

Incorrect content-type header for XSL files in nginx-fpm image #5457

apotek opened this issue Oct 24, 2023 · 13 comments · Fixed by #5458

Comments

@apotek
Copy link
Contributor

apotek commented Oct 24, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Output of ddev debug test

Expand `ddev debug test` diagnostic information
Running bash [-c /var/folders/6m/mbmq3pwx10v1b4jj3t44tsk80000gn/T/test_ddev.sh]
======= Existing project config =========
These config files were loaded for project jfklibrary: [/Users/agarzola/projects/jfkl/.ddev/config.yaml]
name: jfklibrary
type: drupal9
docroot: docroot
php_version: 8.1
webserver_type: nginx-fpm
webimage: ddev/ddev-webserver:v1.22.3
additional_hostnames: []
additional_fqdns: []
database: {mariadb 10.5}
webimage_extra_packages: [chromium libxslt1-dev]
project_tld: ddev.site
use_dns_when_possible: true
composer_version: 2
nodejs_version: 16
default_container_timeout: 120
======= Creating dummy project named  tryddevproject-22214 in ../tryddevproject-22214 =========
OS Information: Darwin vonnegut.lan 22.2.0 Darwin Kernel Version 22.2.0: Fri Nov 11 02:04:44 PST 2022; root:xnu-8792.61.2~4/RELEASE_ARM64_T8103 arm64
ProductName:            macOS
ProductVersion:         13.1
BuildVersion:           22C65
User information: uid=501(agarzola) gid=20(staff) groups=20(staff),12(everyone),61(localaccounts),79(_appserverusr),80(admin),81(_appserveradm),98(_lpadmin),33(_appstore),100(_lpoperator),204(_developer),250(_analyticsusers),395(com.apple.access_ftp),398(com.apple.access_screensharing),399(com.apple.access_ssh),400(com.apple.access_remote_ae),701(com.apple.sharepoint.group.1),702(com.apple.sharepoint.group.2)
DDEV version:  ITEM             VALUE
 DDEV version     v1.22.3
 architecture     arm64
 db               ddev/ddev-dbserver-mariadb-10.4:v1.22.3
 ddev-ssh-agent   ddev/ddev-ssh-agent:v1.22.3
 docker           20.10.22
 docker-compose   v2.21.0
 docker-platform  docker-desktop
 mutagen          0.17.2
 os               darwin
 router           ddev/ddev-traefik-router:v1.22.3
 web              ddev/ddev-webserver:v1.22.3
PROXY settings: HTTP_PROXY='' HTTPS_PROXY='' http_proxy='' NO_PROXY=''
======= DDEV global info =========
Global configuration:
instrumentation-opt-in=true
omit-containers=[]
performance-mode=mutagen
router-bind-all-interfaces=false
internet-detection-timeout-ms=3000
disable-http2=false
use-letsencrypt=false
letsencrypt-email=
table-style=default
simple-formatting=false
auto-restart-containers=false
use-hardened-images=false
fail-on-hook-fail=false
required-docker-compose-version=v2.21.0
use-docker-compose-from-path=false
project-tld=
xdebug-ide-location=
no-bind-mounts=false
router=traefik
wsl2-no-windows-hosts-mgt=false
router-http-port=80
router-https-port=443
mailpit-http-port=8025
mailpit-https-port=8026
traefik-monitor-port=10999

======= DOCKER info =========
docker location: lrwxr-xr-x  1 root  staff  54 Aug  4  2021 /usr/local/bin/docker -> /Applications/Docker.app/Contents/Resources/bin/docker
Docker Desktop Version: Docker Desktop for Mac 4.16.2 build 95914
docker version:
Client:
 Cloud integration: v1.0.29
 Version:           20.10.22
 API version:       1.41
 Go version:        go1.18.9
 Git commit:        3a2c30b
 Built:             Thu Dec 15 22:28:41 2022
 OS/Arch:           darwin/arm64
 Context:           default
 Experimental:      true

Server: Docker Desktop 4.16.2 (95914)
 Engine:
  Version:          20.10.22
  API version:      1.41 (minimum version 1.12)
  Go version:       go1.18.9
  Git commit:       42c8b31
  Built:            Thu Dec 15 22:25:43 2022
  OS/Arch:          linux/arm64
  Experimental:     false
 containerd:
  Version:          1.6.14
  GitCommit:        9ba4b250366a5ddde94bb7c9d1def331423aa323
 runc:
  Version:          1.1.4
  GitCommit:        v1.1.4-0-g5fd4c4d
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0
DOCKER_DEFAULT_PLATFORM=notset
======= Mutagen Info =========
Mutagen is installed in ddev, version=0.17.2
--------------------------------------------------------------------------------
Name: drupal-contrib
Identifier: sync_a5MSMLDxToWHigrl0g9sVx2P4ocJ3EarkXdlq9L9lvR
Labels:
        com.ddev.config-hash: c212281329fb24762a96e1b7a37a19ed84868866
        com.ddev.volume-signature: var-run-1696017118
Configuration:
        Synchronization mode: Two Way Resolved
        Hashing algorithm: Default (SHA-1)
        Maximum allowed entry count: Default (2⁶⁴−1)
        Maximum staging file size: Default (18 EB)
        Symbolic link mode: POSIX Raw
        Ignore VCS mode: Default (Propagate)
        Ignores:
                /.git
                /.tarballs
                /.ddev/db_snapshots
                /.ddev/.importdb*
                .DS_Store
                .idea
                /web/sites/default/files
        Permissions mode: Default (Portable)
Alpha:
        URL: /Users/agarzola/projects/drupal-contrib
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
        Connected: Yes
        Synchronizable contents:
                10019 directories
                51127 files (269 MB)
                121 symbolic links
Beta:
        URL: docker://ddev-drupal-contrib-web/var/www/html
                DOCKER_HOST=unix:///var/run/docker.sock
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
                Compression: Default (DEFLATE)
        Connected: Yes
        Synchronizable contents:
                10019 directories
                51127 files (269 MB)
                121 symbolic links
Status: Watching for changes
--------------------------------------------------------------------------------
Name: jfklibrary
Identifier: sync_xnptbh9tCcbUhLNWVduqeyG2La7nfqesdpe2vVY6DjG
Labels:
        com.ddev.config-hash: 654a7799e053320033f4baa45c0f9c345f2546e4
        com.ddev.volume-signature: var-run-1696350722
Configuration:
        Synchronization mode: Two Way Resolved
        Hashing algorithm: Default (SHA-1)
        Maximum allowed entry count: Default (2⁶⁴−1)
        Maximum staging file size: Default (18 EB)
        Symbolic link mode: POSIX Raw
        Ignore VCS mode: Default (Propagate)
        Ignores:
                /.git
                /.tarballs
                /.ddev/db_snapshots
                /.ddev/.importdb*
                .DS_Store
                .idea
                /docroot/sites/default/files
        Permissions mode: Default (Portable)
Alpha:
        URL: /Users/agarzola/projects/jfkl
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
        Connected: Yes
        Synchronizable contents:
                20311 directories
                92597 files (3.1 GB)
                162 symbolic links
Beta:
        URL: docker://ddev-jfklibrary-web/var/www/html
                DOCKER_HOST=unix:///var/run/docker.sock
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
                Compression: Default (DEFLATE)
        Connected: Yes
        Synchronizable contents:
                20311 directories
                92597 files (3.1 GB)
                162 symbolic links
Status: Watching for changes
--------------------------------------------------------------------------------
Name: imprivata
Identifier: sync_Rbggc3qdxFg1nUWoVIwW98ZkLNdDOoH9NacFj9yiWqp
Labels:
        com.ddev.config-hash: c212281329fb24762a96e1b7a37a19ed84868866
        com.ddev.volume-signature: var-run-1696936737
Configuration:
        Synchronization mode: Two Way Resolved
        Hashing algorithm: Default (SHA-1)
        Maximum allowed entry count: Default (2⁶⁴−1)
        Maximum staging file size: Default (18 EB)
        Symbolic link mode: POSIX Raw
        Ignore VCS mode: Default (Propagate)
        Ignores:
                /.git
                /.tarballs
                /.ddev/db_snapshots
                /.ddev/.importdb*
                .DS_Store
                .idea
                /web/sites/default/files
        Permissions mode: Default (Portable)
Alpha:
        URL: /Users/agarzola/projects/imprivata-drupal-8
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
        Connected: Yes
        Synchronizable contents:
                17333 directories
                86133 files (526 MB)
                190 symbolic links
Beta:
        URL: docker://ddev-imprivata-web/var/www/html
                DOCKER_HOST=unix:///var/run/docker.sock
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
                Compression: Default (DEFLATE)
        Connected: Yes
        Synchronizable contents:
                17333 directories
                86133 files (526 MB)
                190 symbolic links
Status: Watching for changes
--------------------------------------------------------------------------------
Name: benz-platform
Identifier: sync_19UIeSfX3mjYRmoGEA3i3dIPpE5Ug4qPTVdcxvXLfvz
Labels:
        com.ddev.config-hash: c212281329fb24762a96e1b7a37a19ed84868866
        com.ddev.volume-signature: var-run-1696937604
Configuration:
        Synchronization mode: Two Way Resolved
        Hashing algorithm: Default (SHA-1)
        Maximum allowed entry count: Default (2⁶⁴−1)
        Maximum staging file size: Default (18 EB)
        Symbolic link mode: POSIX Raw
        Ignore VCS mode: Default (Propagate)
        Ignores:
                /.git
                /.tarballs
                /.ddev/db_snapshots
                /.ddev/.importdb*
                .DS_Store
                .idea
                /web/sites/default/files
        Permissions mode: Default (Portable)
Alpha:
        URL: /Users/agarzola/projects/benz-platform
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
        Connected: Yes
        Synchronizable contents:
                18782 directories
                84880 files (814 MB)
                324 symbolic links
Beta:
        URL: docker://ddev-benz-platform-web/var/www/html
                DOCKER_HOST=unix:///var/run/docker.sock
        Configuration:
                Watch mode: Default (Portable)
                Watch polling interval: Default (10 seconds)
                Probe mode: Default (Probe)
                Scan mode: Default (Accelerated)
                Stage mode: Neighboring
                File mode: Default (0600)
                Directory mode: Default (0700)
                Default file/directory owner: Default
                Default file/directory group: Default
                Compression: Default (DEFLATE)
        Connected: Yes
        Synchronizable contents:
                18790 directories
                84916 files (815 MB)
                324 symbolic links
Conflicts:
        (alpha) node_modules/anymatch/node_modules/micromatch (Directory -> <non-existent>)
        (beta)  node_modules/anymatch/node_modules/micromatch/lib/.DS_Store (<non-existent> -> Untracked content)

        (alpha) node_modules/glob-watcher/node_modules/micromatch (Directory -> <non-existent>)
        (beta)  node_modules/glob-watcher/node_modules/micromatch/lib/.DS_Store (<non-existent> -> Untracked content)

        (alpha) node_modules/liftoff/node_modules/micromatch (Directory -> <non-existent>)
        (beta)  node_modules/liftoff/node_modules/micromatch/lib/.DS_Store (<non-existent> -> Untracked content)

        (alpha) node_modules/matchdep/node_modules/micromatch (Directory -> <non-existent>)
        (beta)  node_modules/matchdep/node_modules/micromatch/lib/.DS_Store (<non-existent> -> Untracked content)
Status: Watching for changes
--------------------------------------------------------------------------------
======= Docker Info =========
Docker platform: docker-desktop
Using Docker context: default (unix:///var/run/docker.sock)
docker-compose: v2.21.0
Using DOCKER_HOST=unix:///var/run/docker.sock
Docker version: 20.10.22
Able to run simple container that mounts a volume.
Able to use internet inside container.
Docker disk space:
Filesystem                Size      Used Available Use% Mounted on
overlay                 975.1G    145.4G    780.1G  16% /

 Container ddev-benz-platform-redis  Stopped
 Container ddev-benz-platform-db  Stopped
 Container ddev-benz-platform-web  Stopped
 Container ddev-benz-platform-redis  Stopped
 Container ddev-benz-platform-web  Stopped
 Container ddev-benz-platform-db  Stopped
 Container ddev-benz-platform-redis  Removed
 Container ddev-benz-platform-db  Removed
 Container ddev-benz-platform-web  Removed
 Network ddev-benz-platform_default  Removed
Project benz-platform has been stopped.
 Container ddev-drupal-contrib-db  Stopped
 Container ddev-drupal-contrib-web  Stopped
 Container ddev-drupal-contrib-chromedriver  Stopped
 Container ddev-drupal-contrib-db  Stopped
 Container ddev-drupal-contrib-web  Stopped
 Container ddev-drupal-contrib-db  Removed
 Container ddev-drupal-contrib-web  Removed
 Container ddev-drupal-contrib-chromedriver  Stopped
 Container ddev-drupal-contrib-chromedriver  Removed
 Network ddev-drupal-contrib_default  Removed
Project drupal-contrib has been stopped.
 Container ddev-imprivata-redis  Stopped
 Container ddev-imprivata-db  Stopped
 Container ddev-imprivata-solr  Stopped
 Container ddev-imprivata-web  Stopped
 Container ddev-imprivata-db  Stopped
 Container ddev-imprivata-web  Stopped
 Container ddev-imprivata-solr  Stopped
 Container ddev-imprivata-redis  Stopped
 Container ddev-imprivata-solr  Removed
 Container ddev-imprivata-redis  Removed
 Container ddev-imprivata-db  Removed
 Container ddev-imprivata-web  Removed
 Network ddev-imprivata_default  Removed
Project imprivata has been stopped.
 Container ddev-jfklibrary-memcached  Stopped
 Container ddev-jfklibrary-db  Stopped
 Container ddev-jfklibrary-web  Stopped
 Container ddev-jfklibrary-db  Stopped
 Container ddev-jfklibrary-web  Stopped
 Container ddev-jfklibrary-memcached  Stopped
 Container ddev-jfklibrary-memcached  Removed
 Container ddev-jfklibrary-db  Removed
 Container ddev-jfklibrary-web  Removed
 Network ddev-jfklibrary_default  Removed
Project jfklibrary has been stopped.
Stopped Mutagen daemon
The ddev-ssh-agent container has been removed. When you start it again you will have to use 'ddev auth ssh' to provide key authentication again.
Existing docker containers:
CONTAINER ID   IMAGE                                         COMMAND                  CREATED        STATUS                      PORTS                                                                   NAMES
50ad2c4e7834   bitnami/mariadb:10.5.8-debian-10-r74          "/lando-entrypoint.s…"   3 weeks ago    Exited (137) 3 weeks ago                                                                            jfklibrary_database_1
120e9ceb304f   devwithlando/php:8.1-apache-4                 "/lando-entrypoint.s…"   3 weeks ago    Exited (137) 3 weeks ago                                                                            jfklibrary_appserver_1
8a751fabf78a   bitnami/memcached:1.6.1-debian-10-r4          "/lando-entrypoint.s…"   3 weeks ago    Exited (137) 3 weeks ago                                                                            jfklibrary_cache_1
b11568cc12f6   node:16                                       "/lando-entrypoint.s…"   3 weeks ago    Exited (137) 3 weeks ago                                                                            jfklibrary_theme_1
a5cab14dd6e5   traefik:2.2.0                                 "/lando-entrypoint.s…"   4 weeks ago    Exited (137) 3 weeks ago                                                                            landoproxyhyperion5000gandalfedition_proxy_1
be92921dda3c   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_rivian_1
b97667749347   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_showcase_1
087b148e17ad   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_bertelsmann_1
dd208ce4222b   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_seagate_1
fb2ed7d9f8df   redis:7                                       "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_cache_1
a922e3807046   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_levis_1
dc9184ceaa70   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_lam_1
5f30c04fb379   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_synopsys_1
5ed268c0f164   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_gen_1
37d25aee964a   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_autodesk_1
7511e90a01bd   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_uc_1
72f884b2eeb8   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_stripe_1
24d5b0e7b02f   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_common_1
c671fee755df   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_honeywell_1
c4445e93058f   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_bae_1
d9fd1c012768   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_paypal_1
5a4e1bf6492b   bitnami/mariadb:10.3.27-debian-10-r84         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_database_1
3db24ff47907   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_splunk_1
2669fdad792d   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_intuit_1
3a59e811fb07   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_beigene_1
97052b7cd55f   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_okta_1
5444fd2c9c49   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_adobe_1
c1a12740736e   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_csl_1
a29856d45fa5   bitnami/mariadb:10.11                         "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_workday_1
2f7c18c481c4   phpmyadmin/phpmyadmin:5.1.1                   "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_pma_1
fafe86a93f0f   devwithlando/php:8.2-apache-4                 "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_appserver_1
622f8b6b35e8   node:18                                       "/lando-entrypoint.s…"   3 months ago   Exited (137) 3 months ago                                                                           benzplatform_node_1
76e2be0e5ddf   bitnami/mysql:5.7.29-debian-10-r51            "/lando-entrypoint.s…"   5 months ago   Exited (137) 5 months ago                                                                           drupaltest_database_1
0f5893aa9e7e   drupalci/webdriver-chromedriver:production    "/lando-entrypoint.s…"   5 months ago   Exited (137) 5 months ago                                                                           drupaltest_chrome_1
6d55fefc5425   devwithlando/php:8.1-apache-4                 "/lando-entrypoint.s…"   5 months ago   Exited (137) 5 months ago                                                                           drupaltest_appserver_1
08d6e732bf91   bitnami/nginx:1.17.10-debian-10-r52           "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   8080/tcp, 8443/tcp, 127.0.0.1:32777->80/tcp, 127.0.0.1:32776->443/tcp   apipoets_appserver_nginx_1
649c36edff5c   solr:8                                        "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   127.0.0.1:32775->8983/tcp                                               apipoets_search_1
4f93cbf7ddb3   bitnami/mariadb:10.3.27-debian-10-r84         "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   127.0.0.1:32771->3306/tcp                                               apipoets_database_1
088bb1d584f0   mailhog/mailhog:v1.0.1                        "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   1025/tcp, 8025/tcp, 127.0.0.1:32772->80/tcp                             apipoets_mailhog_1
60e7e0a24bbd   redis:5                                       "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   6379/tcp                                                                apipoets_cache_1
9856d582733d   devwithlando/php:8.1-fpm-4                    "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   9000/tcp                                                                apipoets_appserver_1
3f1d1f1853e3   857fd9d35cb7                                  "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago                                                                           apipoets_node_1
b0d80befaf48   857fd9d35cb7                                  "/lando-entrypoint.s…"   6 months ago   Exited (255) 5 months ago   127.0.0.1:32774->443/tcp, 127.0.0.1:32773->6006/tcp                     apipoets_storybook_1
6388feb676fa   bitnami/mysql:5.7.29-debian-10-r51            "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupalcontributions_database_1
d361464ba27b   seleniarm/standalone-chromium:102.0.5005.61   "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupalcontributions_chrome_1
11b99a03a4bd   36465d3622b6                                  "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupalcontributions_appserver_1
a07a04a144ff   bitnami/mysql:5.7.29-debian-10-r51            "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupaldev_database_1
1b1da0d8d3ea   drupalci/webdriver-chromedriver:production    "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupaldev_chrome_1
7f0fb76489e4   36465d3622b6                                  "/lando-entrypoint.s…"   7 months ago   Exited (137) 7 months ago                                                                           drupaldev_appserver_1
Network ddev_default created

 TIP OF THE DAY
 `ddev npm` is the right way to run npm commands in your web container.

Starting tryddevproject-22214...
 Container ddev-ssh-agent  Created
 Container ddev-ssh-agent  Started
ssh-agent container is running: If you want to add authentication to the ssh-agent container, run 'ddev auth ssh' to enable your keys.
 Network ddev-tryddevproject-22214_default  Created
 Container ddev-tryddevproject-22214-web  Created
 Container ddev-tryddevproject-22214-db  Created
 Container ddev-tryddevproject-22214-db  Started
 Container ddev-tryddevproject-22214-web  Started
You have Mutagen enabled and your 'php' project type doesn't have `upload_dirs` set.
For faster startup and less disk usage, set upload_dirs to where your user-generated files are stored.
If this is intended you can disable this warning with `ddev config --disable-upload-dirs-warning`.
Starting Mutagen sync process... This can take some time.
Mutagen sync flush completed in 2s.
For details on sync status 'ddev mutagen st tryddevproject-22214 -l'
 Container ddev-router  Created
 Container ddev-router  Started
Successfully started tryddevproject-22214
Project can be reached at https://tryddevproject-22214.ddev.site https://127.0.0.1:53463
======== Curl of site from inside container:
HTTP/1.1 200 OK
Server: nginx
Date: Tue, 24 Oct 2023 21:17:18 GMT
Content-Type: text/html; charset=UTF-8
Connection: keep-alive
Vary: Accept-Encoding

======== curl -I of http://tryddevproject-22214.ddev.site from outside:
HTTP/1.1 200 OK
Content-Type: text/html; charset=UTF-8
Date: Tue, 24 Oct 2023 21:17:18 GMT
Server: nginx
Vary: Accept-Encoding

======== full curl of http://tryddevproject-22214.ddev.site from outside:
Success accessing database... db via TCP/IP
ddev is working. You will want to delete this project with 'ddev delete -Oy tryddevproject-22214'
======== Project ownership on host:
drwxr-xr-x  4 agarzola  staff  128 Oct 24 17:15 ../tryddevproject-22214
======== Project ownership in container:
drwxr-xr-x 4 agarzola dialout 4096 Oct 24 21:17 /var/www/html
======== In-container filesystem:
Filesystem     Type  1K-blocks      Used Available Use% Mounted on
/dev/vda1      ext4 1022420372 152115248 818335724  16% /var/www
======== curl again of tryddevproject-22214 from host:
Success accessing database... db via TCP/IP
ddev is working. You will want to delete this project with 'ddev delete -Oy tryddevproject-22214'
Thanks for running the diagnostic. It was successful.
Please provide the output of this script in a new gist at gist.github.com
Running ddev launch in 5 seconds

Please run cleanup after debugging with 'ddev debug testcleanup'

Expected Behavior

curl -i "https://mysite.ddev.site/stylesheet.xsl" | grep content-type
content-type: application/xslt+xml

Actual Behavior

curl -i "https://mysite.ddev.site/stylesheet.xsl" | grep content-type
content-type: application/octet-stream

The mimetype is incorrect for XSL files and will break the ability to process XSL from an XML file that includes it.

Steps To Reproduce

  1. Create an XML file in your document root.
  2. Create an XSL stylesheet for that XML document.
  3. Load the XML file. XSL will not process.

Anything else?

No response

@apotek apotek changed the title content-type header for XSL files in incorrect in nginx-fpm image Incorrect content-type header for XSL files in nginx-fpm image Oct 24, 2023
@rfay
Copy link
Member

rfay commented Oct 24, 2023

Thanks for bringing this up. Could you please verify the location of the problem by using the http://127.0.0.1 URL (See ddev describe or ddev start) (which doesn't go through the router), to make sure that you are pointing your finger in the right place here?

Do you get this problem with webserver_type: apache-fpm?

@agarzola
Copy link

Do you get this problem with webserver_type: apache-fpm?

We just confirmed that apache-fpm does not have the same issue.

@rfay
Copy link
Member

rfay commented Oct 24, 2023

Take a look inside the container at /etc/mime.types (ddev exec less /etc/mime.types or ddev ssh and poke around).

I see

application/xslt+xml                            xsl xslt

I don't see any other config for this file type; nothing special in nginx config or anywhere else.

@agarzola
Copy link

Could you please verify the location of the problem by using the http://127.0.0.1 URL (See ddev describe or ddev start) (which doesn't go through the router), to make sure that you are pointing your finger in the right place here?

Not sure if I’m doing it right, but here it goes:

curl -Is https://127.0.0.1:50500/sites/default/files/archives/jfk_ead_xslt_archive.xsl | grep Content-Type
Content-Type: application/octet-stream

@apotek
Copy link
Contributor Author

apotek commented Oct 24, 2023

Take a look inside the container at /etc/mime.types (ddev exec less /etc/mime.types or ddev ssh and poke around).

I see

application/xslt+xml                            xsl xslt

I don't see any other config for this file type; nothing special in nginx config or anywhere else.

Interesting. The default for nginx is

  # Specify MIME types for files.
  include       mime.types;
  default_type  application/octet-stream;

https://github.com/ddev/ddev/blob/c6a8acd6762d68626fef95e408413865f76545b5/containers/ddev-webserver/ddev-webserver-base-files/etc/nginx/nginx.conf#L37C1-L39C42

So somehow the default is not being overridden by the mime.types config.

@rfay
Copy link
Member

rfay commented Oct 24, 2023

I think the issue is probably that the /etc/nginx/mime.types needs additions. You can explore this by just editing that file and doing killall -HUP nginx and seeing if you can fix it. The next step after that is to replace it using a .ddev/web-build/Dockerfile, and the step after that is a PR, would be much appreciated! I think you'll find that the standard distributed nginx mime.types doesn't have xsl in it.

@apotek
Copy link
Contributor Author

apotek commented Oct 24, 2023

I think you'll find that the standard distributed nginx mime.types doesn't have xsl in it.

Exactly where my head was going :) The question is, apache uses the OS default /etc/mime.types. Should nginx be using /etc/mime.types or /etc/nginx/mime.types?

@agarzola
Copy link

Take a look inside the container at /etc/mime.types (ddev exec less /etc/mime.types or ddev ssh and poke around).

Just to confirm, I see what @rfay sees when I ssh into DDEV and cat the mime.types file:

$ cat /etc/mime.types | grep xsl
application/xslt+xml                            xsl xslt

@apotek
Copy link
Contributor Author

apotek commented Oct 24, 2023

Take a look inside the container at /etc/mime.types (ddev exec less /etc/mime.types or ddev ssh and poke around).

Just to confirm, I see what @rfay sees when I ssh into DDEV and cat the mime.types file:

$ cat /etc/mime.types | grep xsl
application/xslt+xml                            xsl xslt

Maybe if our nginx config could include /etc/mime.types instead of the /etc/nginx/mime.types that might do it.

The experiment would be, in /etc/nginx/nginx.conf, line 38:

-   include       mime.types;
+  include       /etc/mime.types;

then sudo killall -HUP nginx. This allows us to rely on the OS mime types, as is generally recommended.

@rfay
Copy link
Member

rfay commented Oct 24, 2023

A starting place for exploration is just sudo cp /etc/mime.types /etc/nginx && sudo killall -HUP nginx

@apotek
Copy link
Contributor Author

apotek commented Oct 24, 2023

So, in digging into this with Alfonso, we discovered:

  1. nginx insists not only on providing its own mime types file (ignoring the OS's mime.types), but it's format is not the same as the OS mime.types file. It follows nginx config syntax, wrapping everything in {}. So copying /etc/mime.types to /etc/nginx/mime.types will not work.

  2. Even though /etc/nginx/mime.types does not follow the syntax of /etc/mime.types, it is still named the same 🤯.

  3. I don't see /etc/nginx/mime.types in the ddev codebase, meaning that the configuration for xsl and xslt is missing in the upstream container (debian:bullseye-slim) ddev is pulling from from the files installed by the package maintainer when ddev installs nginx.

According to https://www.w3.org/TR/xslt20/#media-type-registration, .xsl and .xslt should be registered as application/xsl+xslt.

Solution:

  1. Add this to the upstream container's /etc/ngins/mime.types
application/xsl+xslt                xsl xslt;

No guarantee of how quickly that will get fixed. Upstream containers are:
nginx-fpm pulls FROM ddev/ddev-php-base which pulls FROM debian:bullseye-slim. So we'd have to get this change into debian:bullseye-slim the debian nginx package. 😮‍💨

  1. Brittle but faster: in our build steps edit the /etc/nginx/mime.types. Fortunately we know debian uses GNU sed and awk, so it shouldn't be that harrowing.

Maybe:

awk '/application\/zip/ { print "  application/xslt+xml                  xsl xslt;"; print; next }1' mime.types > /tmp/mime.types
cp /tmp/mime.types /etc/nginx/mime.types
  1. Ship ddev's own*, fully maintained /etc/nginx/mime.types :neckbeard:

I'll throw together a PR for option 2.

@rfay
Copy link
Member

rfay commented Oct 24, 2023

I would say just add /etc/nginx/mime.types to ddev-webserver Dockerfile, using the existing + what you want to add. No sedding required.

@apotek
Copy link
Contributor Author

apotek commented Oct 24, 2023

I would say just add /etc/nginx/mime.types to ddev-webserver Dockerfile, using the existing + what you want to add. No sedding required.

Good call. I did this:

if [ "$DDEV_WEBSERVER_TYPE" = "nginx-fpm" ] ; then
  awk '/application\/zip/ { print "  application/xslt+xml                  xsl xslt;"; print; next }1' /etc/nginx/mime.types > /tmp/mime.types
  mv /tmp/mime.types /etc/nginx/mime.types
elif [ "$DDEV_WEBSERVER_TYPE" = "apache-fpm" ] ; then
    a2enmod proxy_fcgi
    a2enconf php${DDEV_PHP_VERSION}-fpm
    a2dissite 000-default
fi

and hated it.

I'll do what you suggest.

apotek added a commit to apotek/ddev that referenced this issue Oct 24, 2023
apotek added a commit to apotek/ddev that referenced this issue Oct 25, 2023
Don't override the shipping mime.types or we will need
to maintain the whole file. Better to just add what is
needed to the http config

Resolves: ddev#5457
rfay pushed a commit to rfay/ddev that referenced this issue Oct 30, 2023
rfay pushed a commit to rfay/ddev that referenced this issue Oct 30, 2023
Don't override the shipping mime.types or we will need
to maintain the whole file. Better to just add what is
needed to the http config

Resolves: ddev#5457
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants