Skip to content
This repository has been archived by the owner on May 7, 2021. It is now read-only.

Missing PROXY_PASS_URL stops nginx from starting #16

Open
nicolaiskogheim opened this issue Jan 3, 2018 · 5 comments
Open

Missing PROXY_PASS_URL stops nginx from starting #16

nicolaiskogheim opened this issue Jan 3, 2018 · 5 comments

Comments

@nicolaiskogheim
Copy link

nicolaiskogheim commented Jan 3, 2018

This got long, sorry. I learned a lot while trying to formulate an issue I had while using your container, and in the end I guess my only request is to clarify in your README that it's essential that PROXY_PASS_URL is defined in the container. I'm not sure what value to give that variable, but I guess that's an unrelated topic.

I'll leave my original notes so I can reference it from relevant projects if need be.


Hi. I have been trying to figure out why the fabric8-ui container ((hub.docker.com/r/)fabric8/fabric8-ui:<any tag>) I ran never started. That container comes into existence via a a build process too complicated for me to understand where the issue is.

The issue manifests when nginx is starting with a config that has a syntax error:

2018/01/03 01:33:19 [emerg] 27#0:
invalid number of arguments in "set" directive in /etc/nginx/nginx.conf:78

The config that ends up in my container looks like this

#/etc/nginx/nginx.conf:78 in running container
        set $oso ;

I'm not too familiar with that nginx syntax, but that space looked suspicious. The line was introduced in ec6afb6 (3189e0e also relevant), and sure enough, there is a variable there that must have expanded to nothing somewhere.

#root/etc/nginx/nginx.conf:78 in this repo
        set $oso ${PROXY_PASS_URL};

I thought this line in your Dockerfile looked interesting, as it specifically mentions PROXY_PASS_URL

#Dockerfile:26
RUN sed -i "2s/^/\/template.sh \/usr\/share\/nginx\/html\nVARS='\$PROXY_PASS_URL' \/template.sh \/etc\/nginx\/nginx.conf  \n/" /run.sh

That line adds

/template.sh /usr/share/nginx/html
VARS='$PROXY_PASS_URL' /template.sh /etc/nginx/nginx.conf

to line 2 of the run.sh startup script that the base image provides, suggesting that your container should be run with the PROXY_PASS_URL environment variable.

I cannot figure out where the issue is. It may be with

Applying the manifests I mentioned does create a line in a config map that looks interesting, but it isn't given a value there. That config variable is, however, used in the fabric8-ui container (that builds on your image), so it looks to me as if that variable should have a value.

I tried finding out what fabric8io/gofabric8 did, because they use those manifests, but they don't have config in their deploy script regarding proxy pass for nginx as far as I could tell.


@joshuawilson
Copy link

I think it is defined in the build pipeline. I would have to dig around to find that. I think the docker file is only used for the build. When I'm working on it locally, I run it locally.

I agree that the whole project is messy. It is on our list of things to do, to clean it up so that it can be built and run without tribal knowledge.

@DirkTheDaring
Copy link

Why is nobody taking care of this issue . as we see with the reference, the initial report is going back 12 months. I was willing to invest some time if fabric8 is a solution, but now I am unsure, as nobody seems to care to get new people onboard since 12 months if you look back into the issue reports, and
I ask myself if the project is already dead?

@joshuawilson
Copy link

@DirkTheDaring The project is definitely NOT dead, just has more bugs then devs. If you want to submit a PR we'll be happy to review it.

@DirkTheDaring
Copy link

DirkTheDaring commented Jan 7, 2019

thanks Joshua for the kindness to respond, there is an "active rumor mill" about fabric8 - and i was very frustrated to read that, but with the containers not updated since 8 months, it makes sense to me. See content of the article and what is claimed about fabric8
https://medium.com/@jstrachan/fabric8-please-check-out-jenkins-x-instead-8295a025173a

@joshuawilson
Copy link

@DirkTheDaring fabric8 is an umbrella name. It was originally created by James. Some pieces are no longer used by the community and so have been archived. (at least that is my understanding) Other bits are under active development.

This repo is stable and so I haven't had a need to update it in a while. But it is used daily in the deployment of fabric8-ui.

https://github.com/fabric8-ui/fabric8-ui is the main repo where the application is built. When master it updated it goes through the CI/CD pipeline and releases at https://openshift.io

Thanks to your question, I am reminded of this issue and will be looking into it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants