ceph / ceph/calamari

calamari 1.4 branch: modify httpd to be reverse proxy instead of WSGI host

Open
#493 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
345
Forks
175
PR merge metrics
No merged PRs in 30d

Description

Since 1.4, the REST API WSGI application is hosted by calamari-lite at localhost:8002. Should httpd should be configured as a reverse proxy instead of wsgi host?

I think USE_X_FORWARDED_HOST = True may be necessary in calamari_web settings.py for rewriting of absolute URLs.

Something like (for all static assets):

```
Alias /static /opt/calamari/webapp/content/

ProxyPass "!"
= 2.4>
Require all granted

SetHandler None

### repeat for all static assets
### proxy to calamari-lite's gevent pywsgi application
### Option to disable SSL?

= 2.4>
Require all granted

ProxyPass "https://localhost:8002/"
ProxyPassReverse "https://localhost:8002/"
SetHandler None

```

For Django: calamari_web/settings.py

```
USE_X_FORWARDED_HOST = True
```

If this is correct, I will submit a PR.

Contributor guide

No contributing guide indexed for this repository

Research direction

Locate the httpd configuration for the calamari 1.4 branch and read calamari_web/settings.py, focusing on the proposed reverse-proxy and forwarded-host behavior. Verify that static assets remain directly served, the REST API is proxied to calamari-lite on localhost:8002, and absolute URLs are rewritten correctly; resolve the SSL option before considering the work done.

Written by the indexing model from the issue text.

Assessment

Tech stack
apache, django, python
Domain
api, backend, devops
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.