strongloop / apiconnect-docker

IBM API Connect on Docker
Other
26 stars 26 forks source link

Error starting nginx with the Micro Gateway Service #19

Open bobmhong opened 7 years ago

bobmhong commented 7 years ago

Nginx is not starting when I try to use the Micro Gateway service. I'm using OS/X with Docker for Mac - version 1.13.1, build 092cba3

Any ideas? Below are logs:

docker-compose -f docker-compose-microgateway.yaml ps Name Command State Ports

apim /tini -- /startup.sh Up
esmaster /docker-entrypoint.sh /bin ... Up 9200/tcp, 9300/tcp ibmlogstash /bin/sh -c /startup.sh Up
ibmportal /root/tini -- /root/start_ ... Up
make-ssh-keys /bin/sh -c /genkey.sh Exit 0
microgateway /bin/sh -c /usr/bin/app.sh ... Up
microservice /bin/sh -c /usr/bin/app.sh ... Up 8080/tcp
nginx /bin/sh -c /run.sh Exit 1
⌁40% [bobhong:~/gitrepo … apiconnect-docker] master(+1/-1) ± docker-compose logs nginx Attaching to nginx nginx | + cp -f /etc/nginx/nginx.tmpl /etc/nginx/nginx.conf nginx | + sed -i -e s/APIM/apim/g /etc/nginx/nginx.conf nginx | + sed -i -e s/PORTAL/ibmportal/g /etc/nginx/nginx.conf nginx | + sed -i -e s/GATEWAY/microgateway/g /etc/nginx/nginx.conf nginx | + cat /etc/nginx/nginx.conf nginx | worker_processes auto; nginx | nginx | error_log /var/log/nginx/error.log info; nginx | nginx | events { nginx | worker_connections 1024; nginx | } nginx | nginx | stream { nginx | map $ssl_preread_server_name $name { nginx | ibmportal portal_backend; nginx | apim apim_backend; nginx | microgateway gateway_backend; nginx | GWADMIN gateway_admin; nginx | default gateway_backend; nginx | } nginx | nginx | upstream apim_backend { nginx | server apim:443; nginx | } nginx | nginx | upstream portal_backend { nginx | server ibmportal:443; nginx | } nginx | nginx | upstream gateway_backend { nginx | server microgateway:443; nginx | } nginx | upstream gateway_admin { nginx | server microgateway:9090; nginx | } nginx | nginx | server { nginx | listen 0.0.0.0:443; nginx | proxy_pass $name; nginx | ssl_preread on; nginx | } nginx | } nginx | + exec nginx -g 'daemon off;' nginx | 2017/02/10 02:14:40 [emerg] 5#5: "map" directive is not allowed here in /etc/nginx/nginx.conf:10 nginx | nginx: [emerg] "map" directive is not allowed here in /etc/nginx/nginx.conf:10

Thanks,

Bob

LiminZhang2004 commented 7 years ago

Hi there,

I got the same issue. Is there any update on it?

Thanks

Limin

LiminZhang2004 commented 7 years ago

The issue was resolved by getting the latest version of nginx.

sunnygoel8 commented 7 years ago

Installed nginx separately on docker ?