Podman: Difference between revisions
Jump to navigation
Jump to search
(17 intermediate revisions by the same user not shown) | |||
Line 8: | Line 8: | ||
apt upgrade | apt upgrade | ||
apt install podman | apt install podman | ||
==Add Registries== | |||
{| | |||
|valign="top" colspan="2"| | |||
<source lang="bash"> | |||
podman login hub.chorke.org -u academia -p sadaqah! | |||
sudo tee -a /etc/containers/registries.conf >>/dev/null <<'EOF' | |||
[registries.search] | |||
registries = ['hub.chorke.org', 'hub.docker.com', 'docker.io', 'quay.io', 'ghcr.io'] | |||
EOF | |||
</source> | |||
|- | |||
|valign="top" colspan="2"| | |||
---- | |||
|- | |||
|valign="top" colspan="2"| | |||
podman pull chorke/crawler:1.0.00 | |||
|- | |||
|valign="top" colspan="2"| | |||
---- | |||
|- | |||
|valign="top"| | |||
? Please select an image: | |||
▸ hub.chorke.org/chorke/crawler:1.0.00 | |||
hub.docker.com/chorke/crawler:1.0.00 | |||
docker.io/chorke/crawler:1.0.00 | |||
quay.io/chorke/crawler:1.0.00 | |||
ghcr.io/chorke/crawler:1.0.00 | |||
|valign="top"| | |||
✔ hub.chorke.org/chorke/crawler:1.0.00 | |||
Trying to pull hub.chorke.org/chorke/crawler:1.0.00... | |||
Getting image source signatures | |||
Copying blob f910a506b6cb done | |||
Copying blob dff385d19640 [=======>------------------------------] 21.9MiB / 101.3MiB | |||
Copying blob e7c96db7181b done | |||
Copying blob c2274a1a0e27 [=========>----------------------------] 17.9MiB / 67.5MiB | |||
|} | |||
==Manage Images== | ==Manage Images== | ||
Line 30: | Line 71: | ||
|valign='top'| | |valign='top'| | ||
podman login hub.chorke.org -u academia -p sadaqah! | |||
podman login reg.chorke.org -u academia -p sadaqah! | |||
podman logout hub.chorke.org | |||
podman logout reg.chorke.org | |||
|valign='top'| | |valign='top'| | ||
Line 38: | Line 85: | ||
|- | |- | ||
|valign='top'| | |valign='top'| | ||
podman run --name='crawler' -d -p 1983:1983 chorke/crawler:1.0.00 | |||
podman run --rm --name='crawler' -d -p 1983:1983 chorke/crawler:1.0.00 | |||
podman run --rm --name='crawler' -d -p 1983:1983 hub.chorke.org/chorke/crawler:1.0.00 | |||
|valign='top'| | |valign='top'| | ||
ls -lah $HOME/.local/share/containers/storage | |||
rm -rf $HOME/.local/share/containers/cache/* | |||
du -sh $HOME/.local/share/containers | |||
|valign='top'| | |valign='top'| | ||
Line 60: | Line 113: | ||
| valign="top" | | | valign="top" | | ||
* [https://www.redhat.com/sysadmin/share-container-image-podman-save <code>podman save</code> share container images] | |||
* [https://developers.redhat.com/blog/2019/02/21/podman-and-buildah-for-docker-users Podman and Buildah for Docker users] | * [https://developers.redhat.com/blog/2019/02/21/podman-and-buildah-for-docker-users Podman and Buildah for Docker users] | ||
* [https://developers.redhat.com/blog/2020/11/19/transitioning-from-docker-to-podman Transitioning from Docker to Podman] | * [https://developers.redhat.com/blog/2020/11/19/transitioning-from-docker-to-podman Transitioning from Docker to Podman] | ||
* [[Multipass]] | |||
* [[Proxmox]] | |||
* [[Juju]] | |||
|} | |} |
Latest revision as of 23:22, 28 November 2023
. /etc/os-release
echo "deb https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_${VERSION_ID}/ /" | sudo tee /etc/apt/sources.list.d /devel:kubic:libcontainers:stable.list
curl -L "https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_${VERSION_ID}/Release.key" | sudo apt-key add -
apt update apt upgrade apt install podman
Add Registries
podman login hub.chorke.org -u academia -p sadaqah!
sudo tee -a /etc/containers/registries.conf >>/dev/null <<'EOF'
[registries.search]
registries = ['hub.chorke.org', 'hub.docker.com', 'docker.io', 'quay.io', 'ghcr.io']
EOF
| |
| |
podman pull chorke/crawler:1.0.00 | |
| |
? Please select an image: ▸ hub.chorke.org/chorke/crawler:1.0.00 hub.docker.com/chorke/crawler:1.0.00 docker.io/chorke/crawler:1.0.00 quay.io/chorke/crawler:1.0.00 ghcr.io/chorke/crawler:1.0.00 |
✔ hub.chorke.org/chorke/crawler:1.0.00 Trying to pull hub.chorke.org/chorke/crawler:1.0.00... Getting image source signatures Copying blob f910a506b6cb done Copying blob dff385d19640 [=======>------------------------------] 21.9MiB / 101.3MiB Copying blob e7c96db7181b done Copying blob c2274a1a0e27 [=========>----------------------------] 17.9MiB / 67.5MiB |
Manage Images
podman pull fedora:latest podman run -it fedora bash ~/.local/share/containers
Docker Removal
systemctl stop docker yum -y remove docker podman pull fedora:latest
Knowledge
podman logs –latest podman inspect –l podman --version podman version podman --help podman ps |
podman login hub.chorke.org -u academia -p sadaqah! podman login reg.chorke.org -u academia -p sadaqah! podman logout hub.chorke.org podman logout reg.chorke.org |
|
| ||
podman run --name='crawler' -d -p 1983:1983 chorke/crawler:1.0.00 podman run --rm --name='crawler' -d -p 1983:1983 chorke/crawler:1.0.00 podman run --rm --name='crawler' -d -p 1983:1983 hub.chorke.org/chorke/crawler:1.0.00 |
ls -lah $HOME/.local/share/containers/storage rm -rf $HOME/.local/share/containers/cache/* du -sh $HOME/.local/share/containers |