Skip to content
● Grav 2.2 is out: 2x faster cold starts and 96% less memory on big sites. Read the announcement →

MIgrating to 2.0

Started by stell 7 days ago · 4 replies · 234 views
7 days ago

I'm using the Wizard.
Step 5: Test:
When opening the "Open staged admin" I get a white screen.
Cannot post images ATM, so here you go:

https://i.postimg.cc/8zFbQFyR/Desktop-screenshot-28-09-2026-16-53.webp

7 days ago

Thanks for the screenshot, that told me what's going on. The staged admin is loading, but all its files are being requested from /docs/user/plugins/admin2/... instead of from inside the staged folder, so they 404 and you get a white page. That happens when custom_base_url is set in an environment config folder, e.g. user/env/<your-host>/config/system.yaml. The wizard clears that setting for the staged preview, but it only looked in user/config/system.yaml, and an environment folder overrides that one.

Can you check whether you have one? For now you can work around it in the staged copy: open grav-2/user/env/<your-host>/config/system.yaml (or grav-2/user/<your-host>/config/system.yaml on an older layout), set custom_base_url: '', and reload the staged admin. Put your value back in that file after you promote, since the wizard won't know to restore it.

I've fixed this in migrate-grav so it clears the setting in environment folders too and restores it automatically on promote. That will be in the next release (1.0.17). If you don't have custom_base_url set anywhere, let me know and I'll keep digging.

— Andy

6 days ago

Hi there,

this folder/file I don't have: user/env/<your-host>/config/system.yaml

What I see is a system.yaml here: /user/<my-host>/config/system.yaml
The custom_base_url: <my-host> is also inside.

5 days ago

That's the one. user/<my-host>/config/system.yaml is the older way of laying out an environment folder, and it overrides user/config/system.yaml the same way.

Keep that setting, by the way. Login and Email use custom_base_url to build correct links, so it belongs on your site. The only problem is the staged preview: it runs from the /grav-2/ subfolder, and your base URL points everything at the live site root instead, so the staged admin's files 404.

Quickest fix: open the staged copy, grav-2/user/<my-host>/config/system.yaml, set custom_base_url: '' just for the preview, and reload the staged admin. Leave your live site's copy alone. After you promote, put your original value back in that file, because the wizard won't restore a change you made by hand.

Or you can update migrate-grav to 1.0.17, which is out now (bin/gpm update migrate-grav), and run the wizard again. It now finds custom_base_url in both environment folder layouts, blanks it only for the staged preview, and puts it back on its own when you promote.

— Andy

5 days ago

Hi Andy,

Thank you very much. I appreciate your work for a long time.
I'll just use 1.0.17, and if I run into any issues, I'll let you know ;)

Suggested topics

Topic Participants Replies Views Activity
Support · by gravinator, 1 month ago
4 439 5 days ago
Support · by Gravver, 2 weeks ago
6 278 1 week ago
Support · by Marcel, 4 weeks ago
2 336 1 week ago
Support · by blu3prince, 2 weeks ago
1 251 2 weeks ago
Support · by complanar, 3 weeks ago
6 330 2 weeks ago