-
-
Notifications
You must be signed in to change notification settings - Fork 247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] nginx: [emerg] "stream" directive is not allowed here in /etc/nginx/conf.d/stream.conf:3 #324
Comments
I know this is closed and linked to other issues. While #316 does give some guidance toward a resolution, it is locked, so I'm going to add my experience here in hopes that it helps someone else. I would say that the primary issue is that I am not an expert in nginx and that's the reason I'm using SWAG docker image in the first place. So post like this go completely over my head: "The upstream package changed how they ship the default nginx configs, if your existing configs already define a stream block it will break because there can only be one." From the other posts in #316 I surmised that there are breaking changes in this latest release that are incompatible with my configuration. It was not really clear from my logs which config was the issue and, not understanding what a "stream block" is I wasn't sure where to look. Since most of the variables are set in my docker run I just decided to stop and purged the SWAG container. Then, I backed up my config folder and deleted it contents. I restarted and checked the logs to confirmed it was running. After that I just copied the proxy-confs over from the config folder backup and restated the container. Everything is now working on the latest version. |
The container log tells you exactly what to do. From the log above:
|
We will just have to agree to disagree that a message that there is something in one of 13 different files tells you exactly what to do. I just felt my method was a lot simpler than trying to comb through a bunch of files trying to figure out if there are diffs and what the impact may be. Just replace them all and copy back what I needed seemed like the path of least resistance. Again this is primary do to my ignorance. I do appreciate all the work that goes into all this. Just trying to help someone in a similar boat as me. |
You nuked the entire thing and started over. How is that simple? If you didn't intentionally customize the confs, you could have just copied the samples over, or even simpler, you could have deleted them and restarted the container, which would have updated them automatically. We had multiple announcements about them for years. Our changelog lists every time a crucial conf is updated, urging you to update, and links to the specific instructions in the readme. Plus, the first line of each config links to the git history of that specific file if you want to see the details. We can't honestly make it any easier or simpler. But you do you. Only reason I'm responding here is so others don't think they have to nuke and start over which would be an awful solution or a workaround. |
I spent too long trying to figure this issue out myself just now, and I really have to ask why aren't unmodified configs automatically updated? That's most of why this confused me so much. Why would I need to update the config? I just updated! I haven't changed anything in it. I also think communication here needs improvement. If the first reply on #316 had explained that configs aren't automatically updated and gave a reminder as to why the message about differing versions in the log is there, I could've figured this out much quicker. "The container log tells you exactly what to do." being there would've also helped. |
Is there an existing issue for this?
Current Behavior
Reverse proxy stopped working as of the latest release (2.2.0-ls174). I am seeing this error in the logs:
I have been running without error for over a year before this release. I rolled back to 1.32.0-ls172 and it is working fine.
Expected Behavior
SWAG starts and reverse proxy works.
Steps To Reproduce
Restart SWAG container or stop, purge, and rerun the docker run.
Environment
CPU architecture
x86-64
Docker creation
Container logs
The text was updated successfully, but these errors were encountered: