What you’ll learn
- how to upgrade Webiny from 5.4.0 to 5.5.0
Before continuing, make sure to take the necessary precautions, listed in the Overview section.
Make sure to check out the 5.5.0 changelog to get familiar with all the changes introduced in this release.
The first step is to upgrade all
@webiny/* packages, which can be done by running the following command in the root of your project:
Once the upgrade has finished, running the
yarn webiny --version command in your terminal should return
Before running the below
webiny upgrade command, please run the following from your project root:
Running this command will apply a minor fix to the
webiny upgrade command that you're about to execute.
This release includes a couple of smaller changes on the project organization level. To make it easier, we provide a simple Webiny CLI command that will automatically make all the necessary adjustments for you.
Once you've run the above upgrade command, run the following:
Before running the
webiny upgrade command, we recommend that you commit any active code changes you might have in your working branch.
webiny upgrade command has finished, a couple of manual steps remain to be completed, after which, your project should be completely updated.
You can then proceed by committing the changes to your working branch and trying to deploy the project to one of the development or pre-production environment.
apolloLinks.ts file (located in your Website project application)#
Copy and paste the above mentioned
apolloLinks.ts file to
apps/website/code/src/plugins/apolloLinks.ts, and also, make sure it's imported in the index.ts, located in the same
Page React component (located in your Website project application)#
/apps/website/code/src/components/Page/index.tsx file and replace its content with the new one. This change is also related to new pre-rendering related fixes.
webiny watch command enables you to stream logs from your application code directly to your terminal. And while all new projects will have this feature automatically enabled, there are a couple of manual steps that needs to be done for projects that are making the upgrade to version
In api/pulumi/dev/index.ts, upon instantiating both
HeadlessCMS classes, make sure to pass the
WEBINY_LOGS_FORWARD_URL: String(process.env.WEBINY_LOGS_FORWARD_URL) as an environment variable.
This will enable logs forwarding for your main GraphQL API and HeadlessCMS GraphQL API Lambda functions.
4. Fix the
buildFunction in the
transform Lambda Function Handler#
We've received several reports of the
webiny.config.ts not importing the correct
buildFunction. Before doing any deployments, please ensure that the config file imports the correct
After a successful deployment, open your Admin Area to execute the automated upgrade of Headless CMS permissions. It will update permissions data structure on user groups and API keys.
We recommend verifying your CMS permissions after the upgrade, to make sure they reflect exactly what is expected.