Can I run custom .sh files while building docker image?

I want to use docker with custom nginx module. So I have to download nginx, extract, rebuild and install it. It’s a lot of work.

Can I implement this logic in .sh file and ask docker to execute this file while building image. I tried:

  • Docker: go get from a private GitHub repo
  • Not able to replace NGINX with NGINX Plus as reverse proxy for microservices on Google Cloud using Kubernetes
  • Increasing docker volume size using docker-compose
  • maven builds fails inside ubuntu vagrant machine as well as docker instance
  • Node Manager is reachable but the managed server is not reachable
  • Gitlab docker registry pull failed EOF
  • ADD nginx/ /home/fbelov/ 
    RUN ["/home/fbelov/"]

    but it doesn’t work

     ---> Running in e90e561c3b80
    /bin/sh: 1: /home/fbelov/ not found
    INFO[0001] The command [/bin/sh -c /home/fbelov/] returned a non-zero code: 127

  • What are the benefits of using DEB for installation with Dockerfile
  • Less awkward method of using all available CPUs in Docker container:
  • hyperkube proxy, kubelet can't find iptables chain, rkt run --net=host
  • prevent Docker from exposing port on host
  • How to enable the Docker Remote API on Windows
  • Running nginx-proxy in docker with ssl
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.