Gekko: Docker build is not working on windows 10

Created on 23 Aug 2017  路  6Comments  路  Source: askmike/gekko

Note: for support questions, please join our Discord server

  • I'm submitting a ...
    [X] bug report
    [ ] feature request
    [ ] question about the decisions made in the repository

  • Action taken (what you did)
    I have followed your installation process for Docker on your site, and it didn't work

  • Expected result (what you hoped would happen)
    Gekko server is up and running

  • Actual result (unexpected outcome)
    The gekko image doesn't have a starting point. It keeps rebooting

  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, etc)
    $ docker-compose up
    Creating network "gekko_default" with the default driver
    Pulling redis (redis:latest)...
    latest: Pulling from library/redis
    Digest: sha256:a7776895af32e34b1fef997e26c79fa988b40c5cf2a3fb48dc22e0584b648d82
    Status: Downloaded newer image for redis:latest
    Creating gekko_redis_1 ...
    Creating gekko_redis_1 ... done
    Creating gekko_gekko_1 ...
    Creating gekko_gekko_1 ... done
    Attaching to gekko_redis_1, gekko_gekko_1
    redis_1 | 1:C 23 Aug 07:44:34.119 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
    redis_1 | 1:C 23 Aug 07:44:34.119 # Redis version=4.0.1, bits=64, commit=00000000, modified=0, pid=1, just started
    redis_1 | 1:C 23 Aug 07:44:34.119 # Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf
    gekko_1 | standard_init_linux.go:187: exec user process caused "no such file or directory"
    redis_1 | 1:M 23 Aug 07:44:34.122 * Running mode=standalone, port=6379.
    redis_1 | 1:M 23 Aug 07:44:34.122 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
    redis_1 | 1:M 23 Aug 07:44:34.122 # Server initialized
    redis_1 | 1:M 23 Aug 07:44:34.122 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled.
    redis_1 | 1:M 23 Aug 07:44:34.124 * DB loaded from disk: 0.002 seconds
    redis_1 | 1:M 23 Aug 07:44:34.124 * Ready to accept connections
    gekko_gekko_1 exited with code 1
    gekko_1 | standard_init_linux.go:187: exec user process caused "no such file or directory"
    gekko_1 | standard_init_linux.go:187: exec user process caused "no such file or directory"
    gekko_1 | standard_init_linux.go:187: exec user process caused "no such file or directory"
    gekko_gekko_1 exited with code 1

wontfix

Most helpful comment

This is a common problem with Docker on Windows when using .sh files as the entry point. The issue is that /bin/sh is the default shell used to execute the script which does not properly interpret the windows style line endings in the .sh file. The windows style endings are of course automatically converted by GIT on checkout to your match your OS.

You can use a call to dos2unix in the Dockerfile: http://willi.am/blog/2016/08/11/docker-for-windows-dealing-with-windows-line-endings/

Another option is to use .gitattributes to force .sh files to unix style line endings: https://techblog.dorogin.com/case-of-windows-line-ending-in-bash-script-7236f056abe

All 6 comments

What OS do you have, and what version of Docker do you have installed?

I'm using Windows 10, with Docker4Windows

Docker version 17.06.1-ce, build 874a737
Version 17.06.1-ce-win24 (13025)
Channel: stable
54dc09c

It works great on linux:

root@vps450792:~/gekko# docker ps
CONTAINER ID        IMAGE                           COMMAND                  CREATED             STATUS              PORTS                            NAMES
8aa73c6ed81a        gekko_gekko                     "/usr/src/app/dock..."   8 seconds ago       Up 7 seconds        0.0.0.0:3000->3000/tcp           gekko_gekko_1
978223c8fe36        redis:latest                    "docker-entrypoint..."   8 seconds ago       Up 8 seconds        6379/tcp                         gekko_redis_1

Unfortunately I don't have a windows machine to debug this on. Is there you reason you want to run this dockerized on windows?

This is a common problem with Docker on Windows when using .sh files as the entry point. The issue is that /bin/sh is the default shell used to execute the script which does not properly interpret the windows style line endings in the .sh file. The windows style endings are of course automatically converted by GIT on checkout to your match your OS.

You can use a call to dos2unix in the Dockerfile: http://willi.am/blog/2016/08/11/docker-for-windows-dealing-with-windows-line-endings/

Another option is to use .gitattributes to force .sh files to unix style line endings: https://techblog.dorogin.com/case-of-windows-line-ending-in-bash-script-7236f056abe

Worked fine @cmroche , thanks!

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. If you feel this is very a important issue please reach out the maintainer of this project directly via e-mail: gekko at mvr dot me.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

EslamAwwad picture EslamAwwad  路  6Comments

GuyPaddock picture GuyPaddock  路  5Comments

Chroll91 picture Chroll91  路  5Comments

GiordanoFlorian picture GiordanoFlorian  路  4Comments

Oowii picture Oowii  路  4Comments