Correct the database using Adobe Commerce CLI (available for versions 2.2.X)

  1. Log in as, or switch to, the Adobe Commerce file system owner.
  2. Run the following commands:
php <your_magento_install_dir>/bin/magento config:set web/unsecure/base_url http://example.com
php <your_magento_install_dir>/bin/magento config:set web/secure/base_url https://example.com

Set the UPDATE_URLS variable

In your local codebase, in the .magento.env.yaml file set:

 stage:
    deploy:
        UPDATE_URLS: true

Clear configuration cache

For the changes to be applied, clean the configuration cache by running the following command:

php <your_magento_install_dir>/bin/magento cache:clean config

Related article in our developer documentation:

Deploy variables

Previous pageTroubleshooting 503 error caused by necessity to change default Varnish settings
Next pagerobots.txt gives 404 error Adobe Commerce on cloud infrastructure 2.3.x

Commerce


Connect with Experience League at Summit!

Get front-row access to top sessions, hands-on activities, and networking—wherever you are!

Learn more