Raspberry Pi에서 Podman Quadlets를 실행하는 방법
발행: (2026년 2월 17일 오후 08:03 GMT+9)
2 분 소요
원문: Dev.to
Source: Dev.to
Podman 설치
sudo apt update && sudo apt install -y podman
일반적인 출력:
Get:1 http://security.debian.org/debian-security trixie-security InRelease [43.4 kB]
Get:2 http://archive.raspberrypi.org/debian trixie InRelease [54.8 kB]
...
Selecting previously unselected package podman.
(Reading database ... 76622 files and directories currently installed.)
Preparing to unpack .../podman_5.4.2+ds1-2+b2_arm64.deb ...
Unpacking podman (5.4.2+ds1-2+b2) ...
Setting up podman (5.4.2+ds1-2+b2) ...
Processing triggers for man-db (2.13.1-1) ...
사용자 환경 준비
사용자‑레벨 systemd 인스턴스가 부팅 시 시작되고 로그아웃 후에도 계속 실행되도록 사용자를 위해 lingering을 활성화합니다:
sudo loginctl enable-linger $USER
Quadlet 디렉터리 생성
로컬 사용자를 위한 Quadlet 파일은 ~/.config/containers/systemd 아래에 저장됩니다:
mkdir -p ~/.config/containers/systemd
샘플 Quadlet 만들기
간단한 Nginx 컨테이너 Quadlet을 생성합니다:
cat > ~/.config/containers/systemd/hello.container
Welcome to nginx!
...
If you see this page, the nginx web server is successfully installed and
working. Further configuration is required.
For online documentation and support please refer to
[nginx.org](http://nginx.org/).
Commercial support is available at
[nginx.com](http://nginx.com/).
...
부팅 시 서비스 활성화
Quadlet 파일에 [Install] 섹션을 추가하여 일반 systemd 유닛처럼 활성화할 수 있도록 합니다:
cat > ~/.config/containers/systemd/hello.container ../hello.service
Podman과 Quadlet이 설정되면, 컨테이너는 네이티브 systemd 유닛으로 실행되며 부팅 시 자동으로 시작됩니다.