linux:podman

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

両方とも前のリビジョン 前のリビジョン
次のリビジョン
前のリビジョン
次のリビジョン両方とも次のリビジョン
linux:podman [2024/03/22 08:09] – [Buildah を使ってより無駄のない小さなコンテナを作る🤔] ともやんlinux:podman [2024/04/11 09:01] – [レシピ] ともやん
行 301: 行 301:
 <font color="#A2734C">mysql-1       | </font>2024-03-12  5:45:20 0 [Note] mysqld: ready for connections. <font color="#A2734C">mysql-1       | </font>2024-03-12  5:45:20 0 [Note] mysqld: ready for connections.
 <font color="#A2734C">mysql-1       | </font>Version: &apos;10.5.9-MariaDB-1:10.5.9+maria~focal&apos;  socket: &apos;/run/mysqld/mysqld.sock&apos;  port: 3306  mariadb.org binary distribution <font color="#A2734C">mysql-1       | </font>Version: &apos;10.5.9-MariaDB-1:10.5.9+maria~focal&apos;  socket: &apos;/run/mysqld/mysqld.sock&apos;  port: 3306  mariadb.org binary distribution
 +</pre></html></WRAP>
 +</WRAP>
 +
 +==== compose provider ====
 +podman compose は、docker-compose や podman-compose などの外部作成プロバイダーの薄いラッパーです。\\
 +公式: [[https://docs.podman.io/en/stable/markdown/podman-compose.1.html|podman-compose — Podman documentation]] [[gtr>https://docs.podman.io/en/stable/markdown/podman-compose.1.html|翻訳]] より\\
 +
 +podman は compose provider 探して処理を引き渡す🤔\\
 +見つからない場合はエラーになるので、docker-compose、podman-compose をインストールする必要がある。\\
 +<WRAP color_term>
 +<WRAP color_command><html><pre>
 +<font color="#FF8700"><b>$</b></font> <font color="#26A269">podman</font> <font color="#A347BA">--log-level=debug</font> compose version
 +</pre></html></WRAP>
 +<WRAP color_result_hlong><html><pre>
 +<font color="#2AA1B3">INFO</font>[0000] podman filtering at log level debug          
 +<font color="#D0CFCC">DEBU</font>[0000] Called compose.PersistentPreRunE(podman --log-level=debug compose version) 
 +<font color="#D0CFCC">DEBU</font>[0000] Using conmon: &quot;/usr/bin/conmon&quot;              
 +<font color="#2AA1B3">INFO</font>[0000] Using sqlite as database backend             
 +<font color="#D0CFCC">DEBU</font>[0000] Using graph driver overlay                   
 +<font color="#D0CFCC">DEBU</font>[0000] Using graph root /home/tomoyan/.local/share/containers/storage 
 +<font color="#D0CFCC">DEBU</font>[0000] Using run root /run/user/1000/containers     
 +<font color="#D0CFCC">DEBU</font>[0000] Using static dir /home/tomoyan/.local/share/containers/storage/libpod 
 +<font color="#D0CFCC">DEBU</font>[0000] Using tmp dir /run/user/1000/libpod/tmp      
 +<font color="#D0CFCC">DEBU</font>[0000] Using volume path /home/tomoyan/.local/share/containers/storage/volumes 
 +<font color="#D0CFCC">DEBU</font>[0000] Using transient store: false                 
 +<font color="#D0CFCC">DEBU</font>[0000] Not configuring container store              
 +<font color="#D0CFCC">DEBU</font>[0000] Initializing event backend journald          
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime krun initialization failed: no valid executable found for OCI runtime krun: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime crun-wasm initialization failed: no valid executable found for OCI runtime crun-wasm: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime runj initialization failed: no valid executable found for OCI runtime runj: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime kata initialization failed: no valid executable found for OCI runtime kata: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime runc initialization failed: no valid executable found for OCI runtime runc: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime runsc initialization failed: no valid executable found for OCI runtime runsc: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime youki initialization failed: no valid executable found for OCI runtime youki: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Configured OCI runtime ocijail initialization failed: no valid executable found for OCI runtime ocijail: invalid argument 
 +<font color="#D0CFCC">DEBU</font>[0000] Using OCI runtime &quot;/usr/bin/crun&quot;            
 +<font color="#2AA1B3">INFO</font>[0000] Setting parallel job count to 25             
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;docker-compose&quot;: exec: &quot;docker-compose&quot;: executable file not found in $PATH 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;$HOME/.docker/cli-plugins/docker-compose&quot;: exec: &quot;/home/tomoyan/.docker/cli-plugins/docker-compose&quot;: stat /home/tomoyan/.docker/cli-plugins/docker-compose: no such file or directory 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;/usr/local/lib/docker/cli-plugins/docker-compose&quot;: exec: &quot;/usr/local/lib/docker/cli-plugins/docker-compose&quot;: stat /usr/local/lib/docker/cli-plugins/docker-compose: no such file or directory 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;/usr/local/libexec/docker/cli-plugins/docker-compose&quot;: exec: &quot;/usr/local/libexec/docker/cli-plugins/docker-compose&quot;: stat /usr/local/libexec/docker/cli-plugins/docker-compose: no such file or directory 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;/usr/lib/docker/cli-plugins/docker-compose&quot;: exec: &quot;/usr/lib/docker/cli-plugins/docker-compose&quot;: stat /usr/lib/docker/cli-plugins/docker-compose: no such file or directory 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;/usr/libexec/docker/cli-plugins/docker-compose&quot;: exec: &quot;/usr/libexec/docker/cli-plugins/docker-compose&quot;: stat /usr/libexec/docker/cli-plugins/docker-compose: no such file or directory 
 +<font color="#D0CFCC">DEBU</font>[0000] Error looking up compose provider &quot;podman-compose&quot;: exec: &quot;podman-compose&quot;: executable file not found in $PATH 
 +Error: looking up compose provider failed
 +7 errors occurred:
 + * exec: &quot;docker-compose&quot;: executable file not found in $PATH
 + * exec: &quot;/home/tomoyan/.docker/cli-plugins/docker-compose&quot;: stat /home/tomoyan/.docker/cli-plugins/docker-compose: no such file or directory
 + * exec: &quot;/usr/local/lib/docker/cli-plugins/docker-compose&quot;: stat /usr/local/lib/docker/cli-plugins/docker-compose: no such file or directory
 + * exec: &quot;/usr/local/libexec/docker/cli-plugins/docker-compose&quot;: stat /usr/local/libexec/docker/cli-plugins/docker-compose: no such file or directory
 + * exec: &quot;/usr/lib/docker/cli-plugins/docker-compose&quot;: stat /usr/lib/docker/cli-plugins/docker-compose: no such file or directory
 + * exec: &quot;/usr/libexec/docker/cli-plugins/docker-compose&quot;: stat /usr/libexec/docker/cli-plugins/docker-compose: no such file or directory
 + * exec: &quot;podman-compose&quot;: executable file not found in $PATH
 +<font color="#D0CFCC">DEBU</font>[0000] Shutting down engines
 +</pre></html></WRAP>
 +</WRAP>
 +ソースコード: [[git>containers/podman/blob/e64d81481dd0669b60cb2fc94fed9f147e90a102/cmd/podman/compose.go#L73|podman/cmd/podman/compose.go at e64d81481dd0669b60cb2fc94fed9f147e90a102 · containers/podman]]\\
 +
 +Python の podman-compose をインストールする場合🤔\\
 +公式: [[git>containers/podman-compose|containers/podman-compose: a script to run docker-compose.yml using podman]]\\
 +<WRAP color_term>
 +<WRAP color_command><html><pre>
 +<font color="#FF8700"><b>$</b></font> <font color="#26A269">pip</font> install <font color="#A347BA">--user</font> podman-compose
 +</pre></html></WRAP>
 +<WRAP color_result><html><pre>
 +Collecting podman-compose
 +  Obtaining dependency information for podman-compose from https://files.pythonhosted.org/packages/c0/99/0f3be1e471dc6a2b6feff25fc0a9e8d973b5190f227766fe9a2eb95e6d0a/podman_compose-1.0.6-py2.py3-none-any.whl.metadata
 +  Using cached podman_compose-1.0.6-py2.py3-none-any.whl.metadata (5.4 kB)
 +Requirement already satisfied: pyyaml in /usr/lib64/python3.12/site-packages (from podman-compose) (6.0.1)
 +Requirement already satisfied: python-dotenv in ./.local/lib/python3.12/site-packages (from podman-compose) (1.0.1)
 +Using cached podman_compose-1.0.6-py2.py3-none-any.whl (34 kB)
 +Installing collected packages: podman-compose
 +Successfully installed podman-compose-1.0.6
 +</pre></html></WRAP>
 +</WRAP>
 +
 +podman は Python の podman-compose を利用するようになる🤔\\
 +<WRAP color_term>
 +<WRAP color_command><html><pre>
 +<font color="#FF8700"><b>$</b></font> <font color="#26A269">podman</font> compose version
 +</pre></html></WRAP>
 +<WRAP color_result><html><pre><u style="text-decoration-style:single">&gt;&gt;&gt;&gt; Executing external compose provider &quot;/home/tomoyan/.local/bin/podman-compose&quot;. Please refer to the documentation for details. &lt;&lt;&lt;&lt;</u>
 +
 +podman-compose version: 1.0.6
 +[&apos;podman&apos;, &apos;--version&apos;, &apos;&apos;]
 +using podman version: 4.9.3
 +podman-compose version 1.0.6
 +podman --version 
 +podman version 4.9.3
 +exit code: 0
 </pre></html></WRAP> </pre></html></WRAP>
 </WRAP> </WRAP>
行 306: 行 396:
 ==== その他 ==== ==== その他 ====
 [[python:manylinux|manylinux]]\\ [[python:manylinux|manylinux]]\\
 +[[.:podman:fedora_ubi_micro|Fedora 版の UBI Micro を独自に作る方法 (非公式😅)]]\\
  
 ==== 技術情報 ==== ==== 技術情報 ====
行 412: 行 503:
  
 ===== Buildah を使ってより無駄のない小さなコンテナを作る🤔 ===== ===== Buildah を使ってより無駄のない小さなコンテナを作る🤔 =====
-公式: [[https://buildah.io/|Buildah | buildah.io]]\\+公式: [[https://buildah.io/|Buildah | buildah.io]] [[gtr>https://buildah.io/|翻訳]]\\
 ソースコード: [[https://github.com/containers/buildah|containers/buildah: A tool that facilitates building OCI images.]]\\ ソースコード: [[https://github.com/containers/buildah|containers/buildah: A tool that facilitates building OCI images.]]\\
  
行 655: 行 746:
 </panel> </panel>
 </accordion> </accordion>
 +
 +===== Overlay Filesystem =====
 +公式: [[https://docs.kernel.org/filesystems/overlayfs.html|Overlay Filesystem — The Linux Kernel documentation]] [[gtr>https://docs.kernel.org/filesystems/overlayfs.html|翻訳]]\\
  
 ===== レシピ ===== ===== レシピ =====
 [[.:podman:openlitespeed|OpenLiteSpeed (Podman)]]\\ [[.:podman:openlitespeed|OpenLiteSpeed (Podman)]]\\
 [[.:podman:simple-container-registry|podman ローカル プライベート レジストリの構築]]\\ [[.:podman:simple-container-registry|podman ローカル プライベート レジストリの構築]]\\
 +[[.:podman:kali_linux|Kali Linux (Podman)]]\\
  
 ===== トラブルシューティング ===== ===== トラブルシューティング =====
行 4996: 行 5091:
 </WRAP> </WRAP>
  
-動いた😅一時的なものかもしれないが原因不明😇\\+動いた😅一時的なものかもしれないが原因不明だが <html><code>strace podman</code></html> すると治る😇\\
 <WRAP color_term> <WRAP color_term>
 <WRAP color_command><html><pre> <WRAP color_command><html><pre>
行 5027: 行 5122:
 [[https://access.redhat.com/ja/articles/5632841|Universal Base Images (UBI): イメージ、リポジトリー、パッケージ、およびソースコード - Red Hat Customer Portal]]\\ [[https://access.redhat.com/ja/articles/5632841|Universal Base Images (UBI): イメージ、リポジトリー、パッケージ、およびソースコード - Red Hat Customer Portal]]\\
 [[https://bugzilla.redhat.com/show_bug.cgi?id=2039261|2039261 – dnf --installroot ignores gpg keys in installroot path and requires them to be present in the default path]]\\ [[https://bugzilla.redhat.com/show_bug.cgi?id=2039261|2039261 – dnf --installroot ignores gpg keys in installroot path and requires them to be present in the default path]]\\
 +[[https://rheb.hatenablog.com/entry/ubi-micro|【UBI】Red Hatの新しい最軽量コンテナーイメージ:UBI Microの紹介 - 赤帽エンジニアブログ]]\\
  
 [[https://superuser.com/questions/688733/start-a-systemd-service-inside-chroot-from-a-non-systemd-based-rootfs|unix - Start a systemd service inside chroot from a non systemd based rootfs - Super User]] [[gtr>https://superuser.com/questions/688733/start-a-systemd-service-inside-chroot-from-a-non-systemd-based-rootfs|翻訳]]\\ [[https://superuser.com/questions/688733/start-a-systemd-service-inside-chroot-from-a-non-systemd-based-rootfs|unix - Start a systemd service inside chroot from a non systemd based rootfs - Super User]] [[gtr>https://superuser.com/questions/688733/start-a-systemd-service-inside-chroot-from-a-non-systemd-based-rootfs|翻訳]]\\
行 5033: 行 5129:
 [[git>containers/podman/issues/3212|rootless: allow binding privileged ports with CAP_NET_BIND_SERVICE file cap · Issue #3212 · containers/podman]] [[gtr>https://github.com/containers/podman/issues/3212|翻訳]]\\ [[git>containers/podman/issues/3212|rootless: allow binding privileged ports with CAP_NET_BIND_SERVICE file cap · Issue #3212 · containers/podman]] [[gtr>https://github.com/containers/podman/issues/3212|翻訳]]\\
 [[so>questions/413807/is-there-a-way-for-non-root-processes-to-bind-to-privileged-ports-on-linux|Is there a way for non-root processes to bind to "privileged" ports on Linux? - Stack Overflow]]\\ [[so>questions/413807/is-there-a-way-for-non-root-processes-to-bind-to-privileged-ports-on-linux|Is there a way for non-root processes to bind to "privileged" ports on Linux? - Stack Overflow]]\\
 +
 +[[https://www.redhat.com/sysadmin/speeding-container-buildah|Speeding up container image builds with Buildah | Enable Sysadmin]]\\
  
 ==== 付録 ==== ==== 付録 ====
  • linux/podman.txt
  • 最終更新: 2024/05/27 09:36
  • by ともやん