Difference between revisions of "Microk8s registry"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
+ | Simple build/import script | ||
``` | ``` | ||
#!/usr/bin/env bash | #!/usr/bin/env bash | ||
set -e | set -e | ||
− | + | name=mycontainer | |
− | sudo docker build . -t | + | sudo docker build . -t $name |
− | sudo docker save | + | sudo docker save $name > $name.tar |
− | sudo microk8s ctr image import | + | sudo microk8s ctr image import $name.tar |
− | sudo microk8s ctr images ls | grep | + | sudo microk8s ctr images ls | grep $name |
``` | ``` | ||
Revision as of 15:51, 14 April 2021
Simple build/import script
#!/usr/bin/env bash set -e name=mycontainer sudo docker build . -t $name sudo docker save $name > $name.tar sudo microk8s ctr image import $name.tar sudo microk8s ctr images ls | grep $name
https://microk8s.io/docs/registry-images
https://microk8s.io/docs/registry-built-in
https://microk8s.io/docs/registry-private
sudo vim /var/snap/docker/current/config/daemon.json
"insecure-registries" : ["x.x.x.y:32000"],
sudo microk8s ctr images ls name~='localhost:32000'
sudo microk8s ctr images rm localhost:32000/coredns:latest