# 🐳 [macOS / Linux] 2. μ‹œμŠ€ν…œ & μ»¨ν…Œμ΄λ„ˆ DevOps [⬅️ 메인 README둜 λŒμ•„κ°€κΈ°](../README.md) | [πŸ’» Windows κ°€μ΄λ“œ 보기](./WIN-02-SYSTEM-DEVOPS.md) --- ## ⚑ λΉ λ₯Έ 원클릭 μ„€μΉ˜ (Bash) ```bash # 2.1. bottom (CPU/λ©”λͺ¨λ¦¬/λ„€νŠΈμ›Œν¬ μ‹€μ‹œκ°„ λͺ¨λ‹ˆν„°λ§ TUI) curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-bottom.sh?ref_type=heads" | bash # 2.2. all-smi (이쒅 GPU/NPU 가속기 톡합 λͺ¨λ‹ˆν„°λ§ TUI) curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-all-smi.sh?ref_type=heads" | bash # 2.3. Docker (Linux μ „μš© μžλ™ μ„€μΉ˜) curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-docker.sh?ref_type=heads" | bash # 2.4. ctop (μ‹€μ‹œκ°„ μ»¨ν…Œμ΄λ„ˆ λ©”νŠΈλ¦­ λͺ¨λ‹ˆν„°λ§ TUI) curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-ctop.sh?ref_type=heads" | bash # 2.5. lazydocker (도컀 μ»¨ν…Œμ΄λ„ˆΒ·μ΄λ―Έμ§€Β·λ³Όλ₯¨ 톡합 μ œμ–΄ TUI) curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-lazydocker.sh?ref_type=heads" | bash ``` --- ## πŸ“– 도ꡬ별 상세 μ‚¬μš©λ²• 및 단좕킀 ### 2.1. [bottom (btm)](https://github.com/ClementTsang/bottom) 기쑴의 `top`μ΄λ‚˜ `htop`을 μ™„λ²½ν•˜κ²Œ λŒ€μ²΄ν•˜λŠ” ν™”λ €ν•˜κ³  κ°€λ²Όμš΄ 호슀트 μ‹œμŠ€ν…œ λ¦¬μ†ŒμŠ€ λͺ¨λ‹ˆν„°λ§ TUI λ„κ΅¬μž…λ‹ˆλ‹€. * **μ„€μΉ˜ λͺ…λ Ή:** ```bash curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-bottom.sh?ref_type=heads" | bash ``` * **μ£Όμš” νŠΉμ§•:** * **ν’€ κ·Έλž˜ν”½ 차트** β€” CPU 코어별 μ‚¬μš©λ₯ , RAM/Swap, λ„€νŠΈμ›Œν¬ 흐름, λ””μŠ€ν¬ I/O μ‹€μ‹œκ°„ κ·Έλž˜ν”„ν™” * **μ •κ΅ν•œ ν”„λ‘œμ„ΈμŠ€ μ œμ–΄** β€” ν”„λ‘œμ„ΈμŠ€λ₯Ό μ •λ ¬ν•˜κ³  직접 μ œμ–΄ 및 κ°•μ œ μ’…λ£Œ κ°€λŠ₯ ```bash btm # μ‹€ν–‰ λͺ…λ Ήμ–΄ ``` | 단좕킀 | λ™μž‘ | | :--- | :--- | | `q` / `Esc` | ν”„λ‘œκ·Έλž¨ μ’…λ£Œ | | `F1` ~ `F5` | λ©”νŠΈλ¦­ λͺ¨λ‹ˆν„°λ§ νƒ­ 이동 | | `↑` `↓` | ν”„λ‘œμ„ΈμŠ€ λͺ©λ‘ 선택 이동 | | `k` / `dd` | μ„ νƒν•œ λŒ€μƒ ν”„λ‘œμ„ΈμŠ€ κ°•μ œ μ’…λ£Œ (Kill) | | `/` | μ‹€μ‹œκ°„ ν”„λ‘œμ„ΈμŠ€λͺ… 검색 필터링 | --- ### 2.2. [all-smi](https://github.com/lablup/all-smi) Lablupμ—μ„œ κ°œλ°œν•œ 이쒅(Heterogeneous) 가속기 및 GPU/NPU μžμ› 톡합 λͺ¨λ‹ˆν„°λ§ CLI/TUI λ„κ΅¬μž…λ‹ˆλ‹€. `nvidia-smi`λ₯Ό λŒ€μ²΄/ν™•μž₯ν•˜μ—¬ λ‹€μ–‘ν•œ AI 가속기 및 ν΄λŸ¬μŠ€ν„° λ…Έλ“œ κ΄€μ œλ₯Ό μ§€μ›ν•©λ‹ˆλ‹€. * **μ„€μΉ˜ λͺ…λ Ή:** ```bash curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-all-smi.sh?ref_type=heads" | bash ``` * **μ£Όμš” νŠΉμ§•:** * **이쒅 가속기 지원** β€” NVIDIA GPU, Apple Silicon, Intel Gaudi, Google TPU, Rebellions NPU, Furiosa NPU, Tenstorrent NPU λ“± λͺ¨λ‹ˆν„°λ§ 지원 * **μ‹€μ‹œκ°„ μΈν„°λž™ν‹°λΈŒ TUI** β€” GPU/NPU μ‚¬μš©λ₯ , λ©”λͺ¨λ¦¬, μ˜¨λ„, μ „λ ₯ μ†Œλͺ¨λŸ‰ μ‹€μ‹œκ°„ κ·Έλž˜ν”„ μ‹œκ°ν™” * **ν΄λŸ¬μŠ€ν„° λ©”νŠΈλ¦­ κ΄€μ œ** β€” 원격 μ‹œμŠ€ν…œ κ΄€μ œ 및 ν”„λ‘œλ©”ν…Œμš°μŠ€(Prometheus) λ©”νŠΈλ¦­ μΆ”μΆœ κΈ°λŠ₯ 연동 지원 ```bash all-smi # μΈν„°λž™ν‹°λΈŒ λͺ¨λ‹ˆν„°λ§ TUI μ„Έμ…˜ μ‹œμž‘ all-smi --help # 도움말 및 μ‚¬μš© κ°€λŠ₯ μ˜΅μ…˜ 확인 ``` --- ### 2.3. [Docker](https://www.docker.com/) μ»¨ν…Œμ΄λ„ˆ 기반 μ• ν”Œλ¦¬μΌ€μ΄μ…˜ 가상화 ν”Œλž«νΌμž…λ‹ˆλ‹€. * **μ„€μΉ˜ λͺ…λ Ή (Linux μ „μš©):** ```bash curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-docker.sh?ref_type=heads" | bash ``` ```bash docker run hello-world # λ™μž‘ μœ νš¨μ„± ν…ŒμŠ€νŠΈ docker ps # 가동 쀑인 μ»¨ν…Œμ΄λ„ˆ λͺ©λ‘ docker compose up -d # λ©€ν‹° μ»¨ν…Œμ΄λ„ˆ ν™˜κ²½ λ°±κ·ΈλΌμš΄λ“œ ꡬ동 docker build -t . # 둜컬 Dockerfile λΉŒλ“œ ``` > πŸ’‘ **μš΄μ˜μ²΄μ œλ³„ μ‚¬μš© κ°€μ΄λ“œ:** > * **macOS:** [Docker Desktop for Mac](https://www.docker.com/products/docker-desktop/) λ˜λŠ” μ΄ˆκ²½λŸ‰ λŒ€μ•ˆμΈ [OrbStack](https://orbstack.dev/) μ„€μΉ˜λ₯Ό ꢌμž₯ν•©λ‹ˆλ‹€. > * **Linux:** μ„€μΉ˜ μ™„λ£Œ ν›„ μŠ€ν¬λ¦½νŠΈκ°€ 둜그인된 μœ μ €λ₯Ό μžλ™μœΌλ‘œ `docker` κΆŒν•œ 그룹에 ν• λ‹Ήν•©λ‹ˆλ‹€. 터미널 μ„Έμ…˜μ„ μž¬λ‘œκ·ΈμΈν•˜μ‹œλ©΄ `sudo` 없이 νŽΈν•˜κ²Œ μ œμ–΄ν•˜μ‹€ 수 μžˆμŠ΅λ‹ˆλ‹€. --- ### 2.4. [ctop](https://github.com/bcicen/ctop) & 2.5. [lazydocker](https://github.com/jesseduffield/lazydocker) 가동 쀑인 μ»¨ν…Œμ΄λ„ˆλ“€μ„ 효율적으둜 λͺ¨λ‹ˆν„°λ§ν•˜κ³  관리할 수 μžˆλ„λ‘ μ§€μ›ν•˜λŠ” νŠΉν™” TUI λ“€μ˜€μž…λ‹ˆλ‹€. | 도ꡬλͺ… | νŠΉμ§• 및 μ£Όμš” ꢌμž₯ ν™˜κ²½ | | :--- | :--- | | **ctop** | μ‹€μ‹œκ°„ λ¦¬μ†ŒμŠ€ λ©”νŠΈλ¦­(CPU, RAM, λ„€νŠΈμ›Œν¬ νŠΈλž˜ν”½ λ“±) λͺ¨λ‹ˆν„°λ§μ— κ³ λ„λ‘œ νŠΉν™”λ¨ | | **lazydocker** | μ»¨ν…Œμ΄λ„ˆ μƒνƒœ μ‘°νšŒλŠ” 물둠이고 μ‹œμž‘, μ •μ§€, μž¬μ‹œμž‘, 둜그 보기, λ‚΄λΆ€ μ…Έ μ§„μž… λ“± μ „λ°˜μ μΈ μ»¨ν…Œμ΄λ„ˆ 수λͺ… μ£ΌκΈ° 관리에 적합함 | #### [ctop μ„€μΉ˜ 및 μ‚¬μš©λ²•] ```bash # μ„€μΉ˜ curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-ctop.sh?ref_type=heads" | bash # μ‹€ν–‰ ctop ``` | 단좕킀 | λ™μž‘ | | :--- | :--- | | `q` / `Esc` | ν”„λ‘œκ·Έλž¨ μ’…λ£Œ | | `↑` `↓` | μ»¨ν…Œμ΄λ„ˆ 리슀트 이동 | | `l` | μ„ νƒλœ μ»¨ν…Œμ΄λ„ˆμ˜ μ‹€μ‹œκ°„ 둜그 ν™”λ©΄ λ‘œλ“œ | | `a` | μˆ¨κ²¨μ§„ λΉ„ν™œμ„± μ»¨ν…Œμ΄λ„ˆκΉŒμ§€ μ „λΆ€ ν‘œμ‹œ | | `f` | νŠΉμ • μ»¨ν…Œμ΄λ„ˆ 이름 검색 필터링 | | `S` / `R` | μ„ νƒλœ μ»¨ν…Œμ΄λ„ˆ μ •μ§€ / μ¦‰μ‹œ μž¬μ‹œμž‘ | #### [lazydocker μ„€μΉ˜ 및 μ‚¬μš©λ²•] ```bash # μ„€μΉ˜ curl -fsSL "https://gl.isitsoft.kr/publicproj/install-sh/-/raw/main/install-lazydocker.sh?ref_type=heads" | bash # μ‹€ν–‰ lazydocker ``` | 단좕킀 | λ™μž‘ | | :--- | :--- | | `q` | ν”„λ‘œκ·Έλž¨ μ’…λ£Œ | | `↑` `↓` | λͺ©λ‘ νŒ¨λ„ 탐색 | | `Enter` | μ»¨ν…Œμ΄λ„ˆ 상세 둜그 및 μžμ› μ†ŒλΉ„ 톡계 보기 | | `s` / `r` | μ»¨ν…Œμ΄λ„ˆ μΈμŠ€ν„΄μŠ€ μ •μ§€ (Stop) / μž¬μ‹œμž‘ (Restart) | | `e` | μ»¨ν…Œμ΄λ„ˆ λ‚΄λΆ€ 터미널 μ¦‰μ‹œ μ‹€ν–‰ μ§„μž… (Exec) | | `x` | μ»¨ν…Œμ΄λ„ˆ κ°•μ œ 파괴 및 제거 (Remove) | | `[` `]` | νƒ­ 및 νŒ¨λ„ κ°„ μˆ˜ν‰ 포컀슀 이동 | --- [⬅️ 이전: 1. 터미널 관리 & 파일 μœ ν‹Έλ¦¬ν‹°](./UNIX-01-TERMINAL-FILE.md) | [🏠 메인 README](../README.md) | [λ‹€μŒ: 3. 개발 μœ ν‹Έλ¦¬ν‹° ➑️](./UNIX-03-DEV-UTILS.md)