volto icon indicating copy to clipboard operation
volto copied to clipboard

RAZZLE_INTERNAL_API_PATH is always required?

Open csanahuja opened this issue 1 year ago • 2 comments

Describe the bug When I started volto either in dev mode or prod mode without RAZZLE_INTERNAL_API_PATH the redirects were not working. I mean the aliases you can either configure in controlpanel or in each object

To Reproduce See this for context: https://community.plone.org/t/volto-alternate-link-redirect-returns-error-500-solved/19400/2 Essentialy:

  • Start volto with: yarn start or yarn start:prod
  • Create an aliase
  • Browser to the aliase

Expected behavior I would expect the env var not to be required if Plone is in standard path or if its in different path RAZZLE_DEV_PROXY_API_PATH to be sufficient

Software (please complete the following information):

  • OS: Ubuntu 22 / Alma Linux
  • Browser Chrome
  • Volto Version 17.15.5
  • Plone Version 6.0.10
  • Plone REST API Version 9.5

csanahuja avatar Apr 10 '24 09:04 csanahuja

I can't reproduce this on the current main branch of volto

davisagli avatar Apr 12 '24 18:04 davisagli

I can reproduce it with this docker-compose.yml. Maybe in this example it does not make sense to use RAZZLE_DEV_PROXY_PAI_PATH instead of RAZZLE_INTERNAL_API_PATH but it is just to prove that without the later the aliases fail.

version: "3"
services:

  frontend:
   image: plone/plone-frontend:18.0.0-alpha.27
   environment:
     RAZZLE_DEV_PROXY_API_PATH: http://backend:8080/Plone
   ports:
   - "3000:3000"
   depends_on:
     - backend

  backend:
    image: plone/plone-backend:6.0
    environment:
      SITE: Plone
    volumes:
      - data:/data
    ports:
    - "8080:8080"

volumes:
  data: {}

csanahuja avatar Apr 15 '24 11:04 csanahuja