0

I am trying to run this container here: https://github.com/mingfang/docker-predictionio. I built the docker image, but I don't know how to run the 'build' script in the repo. I tried ./build but that gives me this error:

invalid argument "." for "-t, --tag" flag: invalid reference format
See 'docker build --help'.

I am not sure why I am getting this error? I tried passing an argument as a name for the docker image like ./build dockerimage as there is an IMAGE variable in the script. But that also throws the same error. Any ideas?

2 Answers2

0

The $IMAGE variable is set by script helper. This script expects that the repo is in a directory named docker-expecter-image-name, so if you used default checkout options your repo would be in directory docker-predictionio and your $IMAGE would be predictionio. My guess is that you checked out the repo under some other directory name, so the variable $IMAGE is not set correctly.

Note: Script run expects the image to be named predictionio, so if the repo directory is named for example docker-mypredictionio then the build script would execute correctly and the run script would not.

Konrad Botor
  • 4,765
  • 1
  • 16
  • 26
  • Thanks! I appreciate it that worked! That is exactly what happened. Unfortunately though it seems PIO is not working as it should. I ran `pio status` and I am getting an error that it cannot establish connection: `Connection refused (java.net.ConnectException)`. Do you happen to know why this is? I can't seem to find much information doing some googling. – Maaz Mohamedy Jul 27 '18 at 10:06
  • Are you using Windows? If so are you using Docker For Windows of Docker Toolbox? – Konrad Botor Jul 27 '18 at 11:22
  • No I am using Mac – Maaz Mohamedy Jul 27 '18 at 16:56
  • Same question: Docker for Mac or Docker Toolbox? – Konrad Botor Jul 27 '18 at 17:19
  • Docker for Mac. Not Toolbox – Maaz Mohamedy Jul 27 '18 at 17:33
  • I got the same error, because it couldn't connect to elasticsearch. I don't know how to fix this, but since it is outside the scope of your original question, I'd suggest closing this question by accepting my answer and either opening another one with detailed description of your problem or contacting the maintainer of this Docker image – Konrad Botor Jul 28 '18 at 12:13
0

This image are not work because use elasticsearch 5.x, the ES 5.x not allow run as root. Try another image.

Nate
  • 1
  • 1