Chef Server (and Chef Automate) don't support running behind reverse proxy using URL routing
Nobody has claimed this yet.
- Dominant language
- Erlang
- Stars
- 303
- Forks
- 211
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 5
Description
NOTE:
We use GitHub issues to track bugs and feature requests. If you need help please post to our Mailing List or join the Chef Community Slack.
- Chef Community Slack at http://community-slack.chef.io/.
- Chef Mailing List https://discourse.chef.io/
(Note that I looked; https://discourse.chef.io/t/changing-the-chef-server-name-and-or-url/5180 and https://discourse.chef.io/t/changing-chef-api-url/6813 were asked by the same person 3.5 and 5 years ago and no one responded)
Chef Server Version
[What version of Chef Server? Any plugins? Are you using Chef Backend? What versions?]
Chef Server, Chef Automate (latest versions as of Feb 2019)
Platform Details
[Operating system distribution and release version. Cloud provider and instance type if running in the cloud. Total/Free RAM and disk space. Is this running in a container?]
Running on RHEL / CentOS on EC2 instances on AWS
Configuration
[Standalone, Tiered, HA, Chef Backend? New install or upgrade? Ideally include your /etc/opscode/chef-server.rb or otherwise provide details of changes from the default]
Chef and Chef Automate are both running as non-HA
Scenario:
[What you are trying to achieve and you can't?]
We have a reverse proxy that only supports URL based proxying (i.e. we'd like https://myserver/chef to proxy to https://chef.internal and https://myserver/automate to proxy to https://automate.internal). There does not appear to be any documentation on how to do this; unlike gitlab or other tools where you can either specifcy an external URL or otherwise specify a subdirectory for the application to listen for, chef and chefautomate appear to only support a hostname (FQDN).
Steps to Reproduce:
[If you are filing an issue what are the things we need to do in order to repro your problem? How are you using this cookbook or any resources it includes?]
Using stock configuration
Expected Result:
[What are you expecting to happen as the consequence of above reproduction steps?]
https://myexternalproxy/chef brings up the chef login page and all URL's are of the form /chef/ instead of just /
Actual Result:
[What actually happens after the reproduction steps? Include the error output or a link to a gist if possible.]
Fails miserably; redirects to /
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the stock Chef Server configuration behind a URL-based reverse proxy, using the /chef path and the redirect behavior described here. Trace the server's routing and URL generation, then verify that the login page, redirects, and generated links retain the /chef prefix rather than redirecting to /.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- erlang
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100