Docker file to generate kubeturbo container image according to redhat's requirement
As it will install pkgs from RedHat repos, it is necessary to build this image from a RHEL machine which has registered the subscription from RedHat.
subscription-manager register --auto-attach --username=<userName> --password=<passWord>
docker build -t <mytag> .
sh run.sh
docker login -u unused -e none registry.rhc4tp.openshift.com:443
docker tag $imageId registry.rhc4tp.openshift.com:443/$accountId/$tag
docker push registry.rhc4tp.openshift.com:443/$accountId/$tag
Login docker hub first:
docker login docker.io
Then build the image, and push it into docker hub.
docker build -t docker.io/vmturbo/kubeturbo:<tag>
docker push docker.io/vmturbo/kubeturbo:<tag>
If there is an error during push:
...
dda6e8dfdcf7: Waiting
unauthorized: authentication required
Then set up the credentials for docker hub manually. Add/change an item in ~/.docker/config.json
:
{
"auths": {
"https://index.docker.io/v1/": {
"auth": "dXNlcm5hbWU6cGFzc3dvcmQ="
},
}
Note: the auth field should be
username:password
base64 encoded. for example: "username:password" base64 encoded is "dXNlcm5hbWU6cGFzc3dvcmQ="