Comments (4)
Hi @chardskarth, it seems to me the trouble you're running into is due to the docker port mapping in your example. I can reproduce the issue when I run the nginx service with port 80 mapped to port 3002 on the host, but not when I map port 80 to port 80 on the host (this requires the privileged
setting for the nginx container). The reverse proxy is just redirecting the browser to the port that nginx runs on in the container, since it doesn't know that it's being mapped to port 3002.
Like I said, one option is to make the nginx service available on port 80 on the host. Alternatively, you can use the nginx SetHost directive to tell the reverse proxy to tell the browser to connect to the right port.
There's an additional issue with the gollum instance with --base-path
enabled, which I can fix simply by changing the reverse proxy URL. I'll paste my final nginx config below.
In any case, this doesn't seem like a bug in gollun to me, but more of getting gollum, nginx, and Docker to play well together. Let me know if I'm missing anything!
from gollum.
Working nginx config:
server {
listen 80;
server_name ${GOLLUM_HOST};
location / {
proxy_pass http://${GOLLUM_DOCKER_HOSTNAME}:${GOLLUM_DOCKER_PORT}/;
proxy_set_header Host $host:3002;
}
}
server {
listen 80;
server_name ${GENERIC_HOSTNAME};
location /wiki {
proxy_pass http://${GOLLUM_DOCKER_HOSTNAME_WITHPATH}:${GOLLUM_DOCKER_PORT}/wiki;
proxy_set_header Host $host:3002;
}
}
from gollum.
Will close this, but let me know if I've missed anything and this needs to be reopened. :)
from gollum.
Hi man. Thanks a lot for this. Will try this out.
from gollum.
Related Issues (20)
- Running tests fails if git's `init.defaultbranch` is not set to `master` HOT 5
- Setting the gollum author environment variables doesn't make the Git commit use them. HOT 1
- Symlink page edit editing the symlink instead of target + leaves tree with unstaged changes HOT 1
- Investigate server error reporting on save HOT 2
- Failed to install on Ubuntu 22.04 HOT 3
- Failed to run `java gollum.war` resulting in thread error HOT 3
- Ask a question
- Problems caused by language HOT 4
- Navigation macro does not recognize explicit false for sub_path HOT 2
- YAML frontmatter cannot have a folded scalar HOT 1
- git creates 'main' as default branch HOT 1
- Move from RACK_ENV to APP_ENV HOT 4
- Move from master to main as default branch HOT 4
- No API in `A simple, Git-powered wiki with a sweet API and local frontend. ` HOT 6
- Is there any solution we can integrate Apache Echarts in gollum wiki? HOT 3
- We need more templates HOT 3
- Unnecessary content in the overview page HOT 3
- we need to add a language list menu HOT 4
- Unable to create, delete, or rename directory HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gollum.