You are here: How To > Push to the Registry

Push to the Registry

Steps

  1. Download a container image from Docker Hub. In this example, the image is rabbitmq:latest.

    docker pull rabbitmq:latest

    latest: Pulling from library/rabbitmq

    a6a21504c62e: Pull complete

    bf055db89267: Pull complete

    dbd43ef2ea53: Pull complete

    600a59e46bd7: Pull complete

    7232626642cd: Pull complete

    cc290cb80573: Pull complete

    f997bab46fd6: Pull complete

    641325f6925e: Pull complete

    58e1b05f4459: Pull complete

    2dec2d1eea4e: Pull complete

    847202ab44fc: Pull complete

    66e2c8882002: Pull complete

    fbcaa7c864ad: Pull complete

    99bc733dbe0a: Pull complete

    63c04263ad5e: Pull complete

    61e945908a53: Pull complete

    a90ffec32ce7: Pull complete

    3001d59cf838: Pull complete

    be1fddfeb5f6: Pull complete

    Digest: sha256:bb54a2ca1c5e390d1cea32748cc2c9cf927e05740d4962bf889c9e62bcdd3788

    Status: Downloaded newer image for rabbitmq:latest

  2. Log in to Tenable.io Container Security using docker login:

    $ docker login -u TENABLE_IO_CONTAINER_SECURITY_USERNAME -p TENABLE_IO_CONTAINER_SECURITY_PASSWORD registry.tenable.com

    WARNING: login credentials saved in /home/user/.docker/config.json

    Login Succeeded

  3. Get the IMAGE ID using the docker images command:

    $ docker images|grep rabbitmq|grep latest

    rabbitmq 305 MB latest be1fddfeb5f6 2 days ago

    The results are in the following format:

    REPOSITORY VIRTUAL SIZE TAG IMAGE ID CREATED

  4. Tag the image using docker tag:

    $ docker tag be1fddfeb5f6 registry.tenable.com/rabbitmq/rabbitmq

  5. Push the image to Tenable.io Container Security using docker push:

    $ docker push registry.tenable.com/rabbitmq/rabbitmq

    The push refers to a repository [registry.tenable.com/rabbitmq/rabbitmq] (len: 1)

    be1fddfeb5f6: Image already exists

    61e945908a53: Pushed

    63c04263ad5e: Pushed

    fbcaa7c864ad: Pushed

    847202ab44fc: Pushed

    58e1b05f4459: Pushed

    641325f6925e: Pushed

    cc290cb80573: Pushed

    7232626642cd: Pushed

    600a59e46bd7: Pushed

    dbd43ef2ea53: Pushed

    bf055db89267: Pushed

    a6a21504c62e: Pushed

    9ee13ca3b908: Pushed

    latest: digest: sha256:aa6f181d836ce0e91dfeaf08ca671b4e997926919f141c10b2abd37c2af42fe1 size: 35888

    Now rabbitmq:latest is stored in your private instance of Tenable.io Container Security.

Copyright © 2017. Tenable Network Security, Inc. All rights reserved. Tenable Network Security, Nessus, SecurityCenter Continuous View, Passive Vulnerability Scanner, and Log Correlation Engine are registered trademarks of Tenable Network Security, Inc. All other products or services are trademarks of their respective owners.