[SOLVED] Deploying Plone 6 on production: latest version of Volto has problems with URLs when editing content

Hello! I've followed last year the training on how to deploy Plone 6 using containers (GitHub repo). Instead of using Vagrant and Docker Hub, I was able to deploy the docker images (backend, frontend and database) on a server of mine and I used another docker registry instead of Docker Hub.

The customization of Volto is also working with the version of Volto suggested in the training ( @plone/volto": "14.0.0-alpha.23"), but after I updated to the latest version, 14.10.0, I am facing a problem with the internal URLs when editing the content via the main website URL (port 80). For instance, in the /contents, all URLs are duplicated https://mywebsite.com/http://mywebsite.com/rest-of-the-url. Also, when I log in, I am redirected to https://mywebsite.com/http://http://mywebsite.com

I can only edit the content if I access my website using the port 3000 https://mywebsite.com:3000.

Does anyone have some idea what could it be? When I used this alpha version of Volto, I didn't find this issue. Just after building the container with the latest version of Volto I started to face this issue.

P. S. Does anyone recommend some best practices of deploying Plone 6 using containers? Have you some successful case of deployment on production you could share?

Take a look at the upgrade guide. Upgrade Guide - Volto Developer Documentation, also seamless mode Seamless mode - Volto Developer Documentation

2 Likes

Hi, @tiberiuichim. Thank you for the tip. It seems that it was a nginx configuration issue

-    rewrite ^/\+\+api\+\+($|/.*) /VirtualHostBase/http/$server_name/Plone/++api++/VirtualHostRoot/$1 break;
+    rewrite ^/\+\+api\+\+($|/.*) /VirtualHostBase/https/$server_name:443/Plone/++api++/VirtualHostRoot/$1 break;

The problem actually appeared after I added on the server an SSL certificate to my domain. I noticed there was some mistake by reading this section of the documentation you recommended, thank you!

https://docs.voltocms.com/deploying/simple/#reverse-proxies

As a note, now for Plone 6/Volto, I will use the official documentation. But once I was using the official documentation of Plone 5, and I was recommended to follow the training material.

1 Like