-
Notifications
You must be signed in to change notification settings - Fork 1
dockerhub short guide
narategithub edited this page Sep 24, 2020
·
1 revision
This is a short guide on how to update ovishpc images on dockerhub.
- Web Login
- Access Token and CLI Login
- Pull an Image
- Create and Run a Container
- Modify the Container
- Commit the Change
- Push to dockerhub
- Remove the Container
Go to https://hub.docker.com and login with username ovishpc
. Ask Narate for the password, or simply "forgot password" and check [email protected]
e-mail.
- After logged in on the web, go to https://hub.docker.com/settings/security and click "New Access Token".
- Then, name an access token for others to know the purpose of the access token. It may just be your name so that our team knows who created and used the token.
- Click "Create", and don't close the dialog that has the token yet.
- On CLI,
$ docker login --username ovishpc
- Then, paste the token when you're asked for it.
root@baremetal$ docker pull ovishpc/ldmscon2020-single
# Change ldmscon2020-single to any image you want
docker run -it --hostname mycont --name mycont ovishpc/ldmscon2020-single bash
Note:
-
-i
option means interactive,-t
option means tty, so thatbash
in the container connects to your tty. -
--hostname mycont
so that you seemycont
is the container's hostname. If this is not set, a randomly generated hostname will be used an may be confusing when seeing it on the bash prompt. -
--name mycont
to name the containermycont
to make it easy to refer to on the docker host. If this is not given, also another randomly generated name (which is also different from the hostname) will be used and could be confusing.
You may modify the content in the container from bash
within the container, or if you need to copy files from docker host (your bare metal machine) you can use:
root@baremetal$ docker cp FILE_OR_DIR_PATH mycont:DEST_DIR
# Please note that docker cp is recursive, and it will create a new directory in DEST_DIR.
# For example,
# docker cp /home/user mycont:/home/user
# will create /home/user/user directory wile
# docker cp /home/user mycont:/home
# is what we really want
After container modification is done, you can commit its contents to the image on the host CLI as follows:
root@baremetal$ docker commit mycont ovishpc/ldmscon2020-single
root@baremetal$ docker push ovishpc/ldmscon2020-single
When bash
exited, your container will be in stop state, but has not yet been removed. To remove the container:
root@baremetal$ docker rm mycont
- Home
- Search
- Feature Overview
- LDMS Data Facilitates Analysis
- Contributing patches
- User Group Meeting Notes - BiWeekly!
- Publications
- News - now in Discussions
- Mailing Lists
- Help
Tutorials are available at the conference websites
- Coming soon!
- Testing Overview
- Test Plans & Documentation: ldms-test
- Man pages currently not posted, but they are available in the source and build
V3 has been deprecated and will be removed soon
- Configuring
- Configuration Considerations
- Running