You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While investigating the work done by @ahukkanen in #9597, i have noticed that the port of the PR cannot be changed. While investigating further, i came across the below snippet, which uses a wrong ENV variable.
As per documentation, the correct variable should be PORT.
Also, if the environment variable, the UrlOptionResolver should rely on the config.action_controller.default_url_options
Open the terminal and type in PORT=3301 bundle exec rails c
in the console type in Decidim::UserPresenter.new(Decidim::User.first).avatar_url
See that the generated port has remained 3000
Repeat steps 2 by using HTTP_PORT=3301 bundle exec rails c
Repeat steps 3, 4 and observe the port has been changed to 3301
Expected behavior
When using the documented variable for PORT, i should be able to change the URL. Also, any rails default way of customizing the URL should work.
Extra data (please complete the following information):
Device: [e.g. iPhone6, Desktop]
Device OS: [e.g. iOS8.1, Windows 10]
Browser: [e.g. Chrome, Firefox, Safari]
Decidim Version: [e.g. 0.10]
Decidim installation: [e.g. Metadecidim]
Additional context
Add any other context about the problem here. For instance, add Metadecidim link.
Describe the bug
While investigating the work done by @ahukkanen in #9597, i have noticed that the port of the PR cannot be changed. While investigating further, i came across the below snippet, which uses a wrong ENV variable.
decidim/decidim-core/lib/decidim/url_option_resolver.rb
Lines 29 to 44 in 547a565
As per documentation, the correct variable should be
PORT.Also, if the environment variable, the UrlOptionResolver should rely on the
config.action_controller.default_url_optionsReferences:
To Reproduce
Steps to reproduce the behavior:
PORT=3301 bundle exec rails cDecidim::UserPresenter.new(Decidim::User.first).avatar_urlHTTP_PORT=3301 bundle exec rails cExpected behavior
When using the documented variable for PORT, i should be able to change the URL. Also, any rails default way of customizing the URL should work.
Extra data (please complete the following information):
Additional context
Add any other context about the problem here. For instance, add Metadecidim link.