Thank you for beta testing! These instructions describe how to install the Automatic Updates module into a Drupal site, and use it to update Drupal core.
Please report your test result when finished.
Pre-Requisites
- Access to the command line.
- PHP 7.3 or later: run
php --version
or visit/admin/reports/status/php
in your Drupal site to confirm what version is installed. - Composer 2.3.5 or later. Run
composer --version
to find out what version of Composer you have. If it's older than 2.3.5, runcomposer self-update --2
.
Once the pre-requisites are fulfilled, you can either test with a new Drupal site or install Automatic Updates in an existing site.
Testing with a new Drupal Project
The preferred method of creating a site for local development is our fully-automated script--instructions in DEVELOPING.md. If you can't and prefer not to use it, use the following instructions to set it up manually.
- Open a terminal (command line).
-
Run the following commands, replacing
TEST_DIR
with your intended local test directory or your virtualhost directory on a remote test server.composer create-project drupal/recommended-project:9.4.0 TEST_DIR --no-install --no-interaction cd TEST_DIR composer config allow-plugins.composer/installers true composer config allow-plugins.drupal/core-project-message true composer config allow-plugins.drupal/core-composer-scaffold true composer require 'drupal/automatic_updates:^2' --no-interaction --with-all-dependencies
-
Rename the docroot (i.e., browsable site directory), if necessary. For example, on a remote test server, your hosting provider might use
docroot
orhtdocs
.mv web YOUR_DOCROOT
-
For local testing, use Drupal's built-in "quick-start" script to start a lightweight temporary server:
cd YOUR_DOCROOT php ./core/scripts/drupal quick-start standard
You should see a browser open and log you into the new Drupal site.
- For testing on a remote test server, take whatever steps your hosting provider requires to make the new codebase "browseable" and navigate to the test address in your browser.
- You can now take the next steps.
Testing with an existing Drupal Project
- Open the command line and navigate to the directory of your Drupal project.
- Run:
composer require 'drupal/automatic_updates:^2' --with-all-dependencies
- Log in to your Drupal site as an administrator. You can now take the next steps.
- IMPORTANT: If you have Drush installed, please see this note.
Install the Automatic Updates module
- Click "Extend" in the navigation menu.
- Search for "Automatic Updates".
- Select the checkbox for "Automatic Updates".
- Click "Install" button at the bottom of the page.
- You may be redirected to a page detailing additional modules will be enabled. Click the "Continue" button.
- You should see a message telling you that Automatic Updates (and possibly other modules) have been enabled.
Use Automatic Updates to update Drupal
- Ensure you're on the "Extend" page (/admin/modules) and click the "Update" tab.
- You should see a newer version of Drupal as the recommended version. If you installed Automatic Updates into an existing Drupal site, you won't see this if you're already fully up to date. In that case, you may want to start again with a new Drupal project.
- Click the "Update" button. You should be redirected to a page with a progress bar.
- When you see a "Ready to update" screen, click the "Continue" button.
- You should see an "Apply updates" screen with a progress bar.
- You should be redirected to the "Available updates" page and see the message "Update complete!". If database updates are needed, you should be redirected to /update.php to run those; follow the instructions and you should get redirected to the "Available updates" page when finished.
- You should see that Drupal core is fully up-to-date.
You may run into a known issue or limitation; see the project page for more information.
If you have Drush installed: There is a known issue where Drush installs a dependency that contains symbolic links, which can cause Automatic Updates to fail. To get around this, we recommend configuring Automatic Updates to use rsync, if you have it available; run which rsync
or whereis rsync
to determine its location, if it's installed. Then, run the following commands (replace /full/path/to/rsync
with the actual path to rsync):
drush config:set package_manager.settings file_syncer rsync
drush config:set package_manager.settings executables.rsync /full/path/to/rsync
Thanks for testing! Please let us know how it went.
Were these instructions unclear or inaccurate? Please leave a comment on this issue to tell us about it.
Comments
Comment #2
Theresa.GrannumComment #3
Theresa.GrannumComment #4
Theresa.GrannumComment #5
TravisCarden CreditAttribution: TravisCarden at Acquia commented@Theresa.Grannum, there's a fair bit of relevant detail in
#3275810#3308319: Automatic updates 8.x-2.x testing guide for hosting environments that's absent here. Did you consider copying it as a starting point and modifying it from there? Could you try that and insert the following at the top of the "Testing with a new Drupal Project" section?Comment #6
tedbow@TravisCarden I don't think the script will work because the site would be on 9.5.0-dev and we don't support dev through the UI
Comment #7
anish.a CreditAttribution: anish.a as a volunteer commentedI had hit an error that complains about composer not allowing plugins.
If you try to run any composer commands, the composer will prompt you to allow the plugins.
Comment #8
tedbowComment #9
kjankowski CreditAttribution: kjankowski at Frontkom commented@anish.a I had exactly the same problem. I can confirm that simply running
composer install
will help you to add those plugins to allow-plugins section incomposer.json
.Comment #10
TravisCarden CreditAttribution: TravisCarden at Acquia commentedOops, @Theresa.Grannum. I linked to the wrong issue in comment #4. The issue containing the missing detail, which I think this one should be based on, is #3308319: Automatic updates 8.x-2.x testing guide for hosting environments.
@tedbow, that's fine to omit the bit about the local dev setup script. But, for the record, if anyone should choose to take that approach, the script can be easily configured to install whatever version of Drupal core you want using its
DRUPAL_CORE_BRANCH
environment variable (as documented inDEVELOPING.md
). This, for example, would install 9.4.6:Maybe we should change the script to default to the the latest core tag, @tedbow. Otherwise, if we can't recommend that people use it, that seems to defeat its whole purpose.
@anish.a and @kjankowski, the Composer plugins problem is due to outdated instructions here. I've updated the description with the current ones taken from #3308319: Automatic updates 8.x-2.x testing guide for hosting environments. Specifically, see Testing with an existing Drupal Project above.
Comment #11
Theresa.GrannumComment #12
Theresa.GrannumComment #13
tedbowComment #14
phenaproxima8.x-2.x is no longer supported so I'm closing this one out.