silverstripe/silverstripe-installer

Resources folder installed instead of _resources

Closed this issue · 3 comments

Module version(s) affected

5.1.0

Description

Coming from the Slack #cms5 section where I been asked to report the issue on GitHub (Hi!)

The issue is that the installer uses the folder public/resources instead of public/_resources which creates 404 errors when loading the site. Another person also had the same issue.

I used the composer create-project silverstripe/installer xxxxxx ^5 command line so a fresh install via composer.

That's it. Thanks for support, your work and everything!

How to reproduce

just install SS5.1 via composer create-project silverstripe/installer xxxxxx ^5

Possible Solution

No idea, that's a core installation issue so no idea how that's created.

Additional Context

No response

Validations

  • Check that there isn't already an issue that reports the same bug
  • Double check that your reproduction steps work in a fresh installation of silverstripe/installer (with any code examples you've provided)

I can't reproduce this with ubuntu 22.04, PHP 8.1.

What operating system and PHP version are you using? It's possible those have an impact.

Please also provide the full output of composer show after running the composer create-project command, in case there's something weird going on with the versions of packages you're getting.

So yep... I'm on an old Mac Pro early 2008 therefore the latest PHP I've been able to install is PHP 7.4.2 on Mac OS 10.11.6

Obviously once installed on my computer I send everything to a server via SFTP which has PHP8.1 running. I don't have access to the command line on that server so I do it that way.

Here is the complete output of the composer command and I can confirm it repoduces the error with the ressources folder naming. I never had that before with SilverStripe 4.13 and the other folders with _suffix aren't impacted, just for context.

Expand to see composer output
(base) Mac-Pro-de-Gaetan:htdocs gaetankrop$ composer create-project silverstripe/installer test-ressources ^5 --ignore-platform-req PHP
Creating a "silverstripe/installer" project at "./test-ressources"
Installing silverstripe/installer (5.1.0)
  - Installing silverstripe/installer (5.1.0): Extracting archive
Created project in /Applications/MAMP/htdocs/test-ressources
Loading composer repositories with package information
Updating dependencies
Lock file operations: 103 installs, 0 updates, 0 removals
  - Locking composer/ca-bundle (1.5.0)
  - Locking composer/installers (v2.2.0)
  - Locking doctrine/instantiator (2.0.0)
  - Locking doctrine/lexer (3.0.1)
  - Locking egulias/email-validator (4.0.2)
  - Locking embed/embed (v4.4.10)
  - Locking guzzlehttp/guzzle (7.8.1)
  - Locking guzzlehttp/promises (2.0.2)
  - Locking guzzlehttp/psr7 (2.6.2)
  - Locking intervention/image (2.7.2)
  - Locking league/csv (9.15.0)
  - Locking league/flysystem (3.25.1)
  - Locking league/flysystem-local (3.25.1)
  - Locking league/mime-type-detection (1.15.0)
  - Locking m1/env (2.2.0)
  - Locking marcj/topsort (2.0.0)
  - Locking masterminds/html5 (2.8.1)
  - Locking ml/iri (1.1.4)
  - Locking ml/json-ld (1.2.1)
  - Locking monolog/monolog (3.5.0)
  - Locking myclabs/deep-copy (1.11.1)
  - Locking nikic/php-parser (v4.19.1)
  - Locking oscarotero/html-parser (v0.1.8)
  - Locking phar-io/manifest (2.0.4)
  - Locking phar-io/version (3.2.1)
  - Locking phpunit/php-code-coverage (9.2.31)
  - Locking phpunit/php-file-iterator (3.0.6)
  - Locking phpunit/php-invoker (3.1.1)
  - Locking phpunit/php-text-template (2.0.4)
  - Locking phpunit/php-timer (5.0.3)
  - Locking phpunit/phpunit (9.6.18)
  - Locking psr/cache (3.0.0)
  - Locking psr/container (2.0.2)
  - Locking psr/event-dispatcher (1.0.0)
  - Locking psr/http-client (1.0.3)
  - Locking psr/http-factory (1.0.2)
  - Locking psr/http-message (1.1)
  - Locking psr/log (3.0.0)
  - Locking psr/simple-cache (3.0.0)
  - Locking ralouphie/getallheaders (3.0.3)
  - Locking sebastian/cli-parser (1.0.2)
  - Locking sebastian/code-unit (1.0.8)
  - Locking sebastian/code-unit-reverse-lookup (2.0.3)
  - Locking sebastian/comparator (4.0.8)
  - Locking sebastian/complexity (2.0.3)
  - Locking sebastian/diff (4.0.6)
  - Locking sebastian/environment (5.1.5)
  - Locking sebastian/exporter (4.0.6)
  - Locking sebastian/global-state (5.0.7)
  - Locking sebastian/lines-of-code (1.0.4)
  - Locking sebastian/object-enumerator (4.0.4)
  - Locking sebastian/object-reflector (2.0.4)
  - Locking sebastian/recursion-context (4.0.5)
  - Locking sebastian/resource-operations (3.0.4)
  - Locking sebastian/type (3.2.1)
  - Locking sebastian/version (3.0.2)
  - Locking silverstripe-themes/simple (3.3.1)
  - Locking silverstripe/admin (2.1.21)
  - Locking silverstripe/asset-admin (2.1.5)
  - Locking silverstripe/assets (2.1.2)
  - Locking silverstripe/campaign-admin (2.1.1)
  - Locking silverstripe/cms (5.1.6)
  - Locking silverstripe/config (2.1.0)
  - Locking silverstripe/errorpage (2.1.2)
  - Locking silverstripe/event-dispatcher (1.0.0)
  - Locking silverstripe/framework (5.1.22)
  - Locking silverstripe/graphql (5.1.3)
  - Locking silverstripe/login-forms (5.1.2)
  - Locking silverstripe/mimevalidator (3.0.1)
  - Locking silverstripe/recipe-cms (5.1.0)
  - Locking silverstripe/recipe-core (5.1.0)
  - Locking silverstripe/recipe-plugin (2.0.0)
  - Locking silverstripe/reports (5.1.1)
  - Locking silverstripe/session-manager (2.1.1)
  - Locking silverstripe/siteconfig (5.1.2)
  - Locking silverstripe/vendor-plugin (2.0.2)
  - Locking silverstripe/versioned (2.1.3)
  - Locking silverstripe/versioned-admin (2.1.3)
  - Locking sminnee/callbacklist (0.1.1)
  - Locking symfony/cache (v6.4.4)
  - Locking symfony/cache-contracts (v3.4.0)
  - Locking symfony/config (v6.4.4)
  - Locking symfony/deprecation-contracts (v3.4.0)
  - Locking symfony/dom-crawler (v6.4.4)
  - Locking symfony/event-dispatcher (v6.4.3)
  - Locking symfony/event-dispatcher-contracts (v3.4.0)
  - Locking symfony/filesystem (v6.4.3)
  - Locking symfony/finder (v6.4.0)
  - Locking symfony/mailer (v6.4.4)
  - Locking symfony/mime (v6.4.3)
  - Locking symfony/polyfill-ctype (v1.29.0)
  - Locking symfony/polyfill-intl-idn (v1.29.0)
  - Locking symfony/polyfill-intl-normalizer (v1.29.0)
  - Locking symfony/polyfill-mbstring (v1.29.0)
  - Locking symfony/polyfill-php72 (v1.29.0)
  - Locking symfony/service-contracts (v3.4.1)
  - Locking symfony/translation (v6.4.4)
  - Locking symfony/translation-contracts (v3.4.1)
  - Locking symfony/var-exporter (v7.0.4)
  - Locking symfony/yaml (v6.4.3)
  - Locking theseer/tokenizer (1.2.3)
  - Locking ua-parser/uap-php (v3.9.14)
  - Locking webonyx/graphql-php (v15.11.1)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 103 installs, 0 updates, 0 removals
  - Installing composer/installers (v2.2.0): Extracting archive
  - Installing silverstripe/recipe-plugin (2.0.0): Extracting archive
  - Installing silverstripe/vendor-plugin (2.0.2): Extracting archive
  - Installing doctrine/lexer (3.0.1): Extracting archive
  - Installing psr/http-message (1.1): Extracting archive
  - Installing psr/http-factory (1.0.2): Extracting archive
  - Installing psr/http-client (1.0.3): Extracting archive
  - Installing oscarotero/html-parser (v0.1.8): Extracting archive
  - Installing ml/iri (1.1.4): Extracting archive
  - Installing ml/json-ld (1.2.1): Extracting archive
  - Installing symfony/polyfill-mbstring (v1.29.0): Extracting archive
  - Installing composer/ca-bundle (1.5.0): Extracting archive
  - Installing embed/embed (v4.4.10): Extracting archive
  - Installing symfony/deprecation-contracts (v3.4.0): Extracting archive
  - Installing ralouphie/getallheaders (3.0.3): Extracting archive
  - Installing guzzlehttp/psr7 (2.6.2): Extracting archive
  - Installing guzzlehttp/promises (2.0.2): Extracting archive
  - Installing guzzlehttp/guzzle (7.8.1): Extracting archive
  - Installing intervention/image (2.7.2): Extracting archive
  - Installing league/csv (9.15.0): Extracting archive
  - Installing league/mime-type-detection (1.15.0): Extracting archive
  - Installing league/flysystem-local (3.25.1): Extracting archive
  - Installing league/flysystem (3.25.1): Extracting archive
  - Installing m1/env (2.2.0): Extracting archive
  - Installing marcj/topsort (2.0.0): Extracting archive
  - Installing psr/log (3.0.0): Extracting archive
  - Installing monolog/monolog (3.5.0): Extracting archive
  - Installing sebastian/version (3.0.2): Extracting archive
  - Installing sebastian/type (3.2.1): Extracting archive
  - Installing sebastian/resource-operations (3.0.4): Extracting archive
  - Installing sebastian/recursion-context (4.0.5): Extracting archive
  - Installing sebastian/object-reflector (2.0.4): Extracting archive
  - Installing sebastian/object-enumerator (4.0.4): Extracting archive
  - Installing sebastian/global-state (5.0.7): Extracting archive
  - Installing sebastian/exporter (4.0.6): Extracting archive
  - Installing sebastian/environment (5.1.5): Extracting archive
  - Installing sebastian/diff (4.0.6): Extracting archive
  - Installing sebastian/comparator (4.0.8): Extracting archive
  - Installing sebastian/code-unit (1.0.8): Extracting archive
  - Installing sebastian/cli-parser (1.0.2): Extracting archive
  - Installing phpunit/php-timer (5.0.3): Extracting archive
  - Installing phpunit/php-text-template (2.0.4): Extracting archive
  - Installing phpunit/php-invoker (3.1.1): Extracting archive
  - Installing phpunit/php-file-iterator (3.0.6): Extracting archive
  - Installing theseer/tokenizer (1.2.3): Extracting archive
  - Installing nikic/php-parser (v4.19.1): Extracting archive
  - Installing sebastian/lines-of-code (1.0.4): Extracting archive
  - Installing sebastian/complexity (2.0.3): Extracting archive
  - Installing sebastian/code-unit-reverse-lookup (2.0.3): Extracting archive
  - Installing phpunit/php-code-coverage (9.2.31): Extracting archive
  - Installing phar-io/version (3.2.1): Extracting archive
  - Installing phar-io/manifest (2.0.4): Extracting archive
  - Installing myclabs/deep-copy (1.11.1): Extracting archive
  - Installing doctrine/instantiator (2.0.0): Extracting archive
  - Installing phpunit/phpunit (9.6.18): Extracting archive
  - Installing psr/simple-cache (3.0.0): Extracting archive
  - Installing symfony/polyfill-ctype (v1.29.0): Extracting archive
  - Installing symfony/yaml (v6.4.3): Extracting archive
  - Installing symfony/translation-contracts (v3.4.1): Extracting archive
  - Installing symfony/translation (v6.4.4): Extracting archive
  - Installing symfony/polyfill-php72 (v1.29.0): Extracting archive
  - Installing symfony/polyfill-intl-normalizer (v1.29.0): Extracting archive
  - Installing symfony/polyfill-intl-idn (v1.29.0): Extracting archive
  - Installing symfony/mime (v6.4.3): Extracting archive
  - Installing psr/container (2.0.2): Extracting archive
  - Installing symfony/service-contracts (v3.4.1): Extracting archive
  - Installing psr/event-dispatcher (1.0.0): Extracting archive
  - Installing symfony/event-dispatcher-contracts (v3.4.0): Extracting archive
  - Installing symfony/event-dispatcher (v6.4.3): Extracting archive
  - Installing egulias/email-validator (4.0.2): Extracting archive
  - Installing symfony/mailer (v6.4.4): Extracting archive
  - Installing symfony/filesystem (v6.4.3): Extracting archive
  - Installing masterminds/html5 (2.8.1): Extracting archive
  - Installing symfony/dom-crawler (v6.4.4): Extracting archive
  - Installing symfony/config (v6.4.4): Extracting archive
  - Installing symfony/var-exporter (v7.0.4): Extracting archive
  - Installing psr/cache (3.0.0): Extracting archive
  - Installing symfony/cache-contracts (v3.4.0): Extracting archive
  - Installing symfony/cache (v6.4.4): Extracting archive
  - Installing sminnee/callbacklist (0.1.1): Extracting archive
  - Installing symfony/finder (v6.4.0): Extracting archive
  - Installing silverstripe/config (2.1.0): Extracting archive
  - Installing silverstripe/framework (5.1.22): Extracting archive
  - Installing silverstripe/assets (2.1.2): Extracting archive
  - Installing silverstripe-themes/simple (3.3.1): Extracting archive
  - Installing silverstripe/event-dispatcher (1.0.0): Extracting archive
  - Installing silverstripe/login-forms (5.1.2): Extracting archive
  - Installing silverstripe/versioned (2.1.3): Extracting archive
  - Installing webonyx/graphql-php (v15.11.1): Extracting archive
  - Installing silverstripe/graphql (5.1.3): Extracting archive
  - Installing silverstripe/admin (2.1.21): Extracting archive
  - Installing silverstripe/versioned-admin (2.1.3): Extracting archive
  - Installing silverstripe/siteconfig (5.1.2): Extracting archive
  - Installing ua-parser/uap-php (v3.9.14): Extracting archive
  - Installing silverstripe/session-manager (2.1.1): Extracting archive
  - Installing silverstripe/reports (5.1.1): Extracting archive
  - Installing silverstripe/mimevalidator (3.0.1): Extracting archive
  - Installing silverstripe/recipe-core (5.1.0): Extracting archive
  - Installing silverstripe/campaign-admin (2.1.1): Extracting archive
  - Installing silverstripe/cms (5.1.6): Extracting archive
  - Installing silverstripe/errorpage (2.1.2): Extracting archive
  - Installing silverstripe/asset-admin (2.1.5): Extracting archive
  - Installing silverstripe/recipe-cms (5.1.0): Extracting archive
Writing .htaccess to resources folder
Exposing web directories for silverstripe-vendormodule silverstripe/framework with method auto:
  - client/images
  - client/styles
Exposing web directories for silverstripe-theme silverstripe-themes/simple with method auto:
  - css
  - images
  - javascript
  - webfonts
Exposing web directories for silverstripe-vendormodule silverstripe/login-forms with method auto:
  - client/dist
Exposing web directories for silverstripe-vendormodule silverstripe/admin with method auto:
  - client/dist
  - client/lang
  - thirdparty
Exposing web directories for silverstripe-vendormodule silverstripe/versioned-admin with method auto:
  - client/dist
Exposing web directories for silverstripe-vendormodule silverstripe/session-manager with method auto:
  - client/dist
Exposing web directories for silverstripe-vendormodule silverstripe/reports with method auto:
  - javascript
Installing project files for recipe silverstripe/recipe-core:
  - Copying .htaccess
  - Copying app/.htaccess
  - Copying app/_config/mimevalidator.yml
  - Copying app/_config/mysite.yml
Installing public files for recipe silverstripe/recipe-core:
  - Copying .htaccess
  - Copying index.php
  - Copying web.config
Exposing web directories for silverstripe-vendormodule silverstripe/campaign-admin with method auto:
  - client/dist
  - client/lang
Exposing web directories for silverstripe-vendormodule silverstripe/cms with method auto:
  - client/dist
  - client/lang
Exposing web directories for silverstripe-vendormodule silverstripe/asset-admin with method auto:
  - client/dist
  - client/lang
Installing project files for recipe silverstripe/recipe-cms:
  - Copying app/src/Page.php
  - Copying app/src/PageController.php
27 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
63 packages you are using are looking for funding.
Use the `composer fund` command to find out more!

the latest PHP I've been able to install is PHP 7.4.2

Silverstripe CMS 5.x is not compatible with PHP 7.4. Using --ignore-platform-req does let the packages install, but you should expect things to not work correctly.

I'm going to close this issue - though if someone experiences this with a supported version of PHP I'm happy to reopen at that stage.

@digitweaks I recommend installing docker and using ddev so that you can use supported versions of PHP.