-
Notifications
You must be signed in to change notification settings - Fork 1
Create a Docker image
To be able to create a job for the Neuromation Platform you should create a Docker image first.
You can do it by creating a Dockerfile
. A Dockerfile
is a text document that contains all the commands a user could call on the command line to assemble an image.
Let's conside the given Dockerfile
:
FROM ufoym/deepo:cpu
RUN apt-get update
RUN add-apt-repository ppa:deadsnakes/ppa
RUN apt-get update
RUN apt-get install -y build-essential python3.6 python3.6-dev python3.6-venv git sudo
RUN python3.6 -m pip install pip --upgrade
If you are not familiar with Dockerfiles, refer to the documentation for more information.
Using docker build
you can build an image from a Dockerfile
:
$ docker build -t platform-api-hello-world .
Once you've built the image, you should push it into Neuromation registry to be able to create jobs from it. In order for you to be able to upload new images you have to login into the platform:
$ neuro config auth <TOKEN>
$ curl -s -H "Authorization: Bearer <TOKEN>" https://platform.staging.neuromation.io/api/v1/storage/\?liststatus
Use neuro image push
command to upload the image:
$ neuro image push platform-api-hello-world:latest
Awesome! You have uploaded your first image into the Neuromation Platform!
Take a look on the next part of this tutorial to understand how to run jobs.