Have drupal-scaffold locations web-root for Varbase as docroot to fix composer web-root folder in projects

Created on 3 August 2022, almost 2 years ago
Updated 6 July 2023, 12 months ago

Problem/Motivation

Composer is fixed to docroot folder and should use web-root such as core composer to let use this project into custom folder.

Steps to reproduce

Having issues with custom composer build with Varbase profile conflicting with changes over Varbase Project template
When changed in projects, composer will face issues on builds and updates

Proposed resolution

1. Double-check what Drupal Recommended Project
https://github.com/drupal/recommended-project/blob/9.4.5/composer.json#L43
2. Check Acquia Drupal Recommended Project
https://github.com/acquia/drupal-recommended-project/blob/1.11.19/compos...

3. Use the right web-root in both Varbase profile and Varbase Project template

    "drupal-scaffold": {
      "allowed-packages": [
        "drupal/core",
        "vardot/varbase"
      ],
      "gitignore": true,
      "locations": {
        "web-root": "./docroot"
      },
      "file-mapping": {
        "[web-root]/sites/default/default.services.yml": {
          "mode": "replace",
          "overwrite": false,
          "path": "docroot/core/assets/scaffold/files/default.services.yml"
        },
        "[web-root]/sites/default/default.settings.php": {
          "mode": "replace",
          "overwrite": false,
          "path": "docroot/core/assets/scaffold/files/default.settings.php"
        },
        "[web-root]/robots.txt": {
          "append": "docroot/profiles/varbase/src/assets/varbase-robots-additions.txt"
        }
      }
    },

Projects could change "web-root": "docroot/" and docroot to web using change or a clone of the Varbase Project Template
Have drupal-scaffold locations web-root for Varbase Project template as docroot to fix composer web-root folder in projects #146

Remaining tasks

  • βœ… File an issue about this project
  • βœ… Addition/Change/Update/Fix to this project
  • βœ… Testing to ensure no regression
  • βž– Automated unit/functional testing coverage
  • βž– Developer Documentation support on feature change/addition
  • βž– User Guide Documentation support on feature change/addition
  • βž– Accessibility and Readability
  • βœ… Code review from 1 Varbase core team member
  • βœ… Full testing and approval
  • βœ… Credit contributors
  • βœ… Review with the product owner
  • βœ… Update Release Notes and Update Helper on new feature change/addition
  • βœ… Release varbase-9.0.8 β†’

Varbase update type

  • βœ… No Update
  • βž– Optional Update
  • βž– Forced Update
  • βž– Forced Update if Unchanged

User interface changes

  • N/A

API changes

  • N/A

Data model changes

  • N/A

Release notes snippet

  • Issue #3301451 β†’ by vacho β†’ : Have drupal-scaffold locations web-root for Varbase as docroot to fix composer web-root folder in projects
πŸ“Œ Task
Status

Fixed

Version

9.0

Component

Code

Created by

πŸ‡§πŸ‡΄Bolivia vacho Cochabamba

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024