Files
proxmox/docs/12-quick-reference/QUICK_START_TEMPLATE.md
defiQUG fbda1b4beb
Some checks failed
Deploy to Phoenix / deploy (push) Has been cancelled
docs: Ledger Live integration, contract deploy learnings, NEXT_STEPS updates
- ADD_CHAIN138_TO_LEDGER_LIVE: Ledger form done; public code review repo bis-innovations/LedgerLive; init/push commands
- CONTRACT_DEPLOYMENT_RUNBOOK: Chain 138 gas price 1 gwei, 36-addr check, TransactionMirror workaround
- CONTRACT_*: AddressMapper, MirrorManager deployed 2026-02-12; 36-address on-chain check
- NEXT_STEPS_FOR_YOU: Ledger done; steps completable now (no LAN); run-completable-tasks-from-anywhere
- MASTER_INDEX, OPERATOR_OPTIONAL, SMART_CONTRACTS_INVENTORY_SIMPLE: updates
- LEDGER_BLOCKCHAIN_INTEGRATION_COMPLETE: bis-innovations/LedgerLive reference

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 15:46:57 -08:00

109 lines
2.7 KiB
Markdown

# Quick Start: Using Template as Base for All LXCs
**Last Updated:** 2026-01-31
**Document Version:** 1.0
**Status:** Active Documentation
---
## Step 1: Choose Your Base Template
Run the template script to see available options:
```bash
bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/tools/addon/all-templates.sh)"
```
Or list available templates directly:
```bash
pveam available | grep -E "debian|ubuntu|alpine"
```
## Step 2: Download the Template (Once)
For example, Debian 12:
```bash
pveam download local debian-12-standard_12.2-1_amd64.tar.zst
```
This downloads the template to your local storage. You only need to do this once.
## Step 3: Set Template Variable
Create or update your configuration file with:
```bash
# In your deployment config file or .env
export CONTAINER_OS_TEMPLATE="local:vztmpl/debian-12-standard_12.2-1_amd64.tar.zst"
```
## Step 4: Deploy Multiple Containers
Now you can deploy as many containers as needed from this single template:
```bash
# Container 1 - Web Server
pct create 100 "$CONTAINER_OS_TEMPLATE" \
--hostname web1 \
--memory 2048 \
--cores 2 \
--rootfs local-lvm:20 \
--net0 name=eth0,bridge=vmbr0,ip=dhcp \
--unprivileged 1
# Container 2 - Database
pct create 101 "$CONTAINER_OS_TEMPLATE" \
--hostname db1 \
--memory 4096 \
--cores 4 \
--rootfs local-lvm:50 \
--net0 name=eth0,bridge=vmbr0,ip=dhcp \
--unprivileged 1
# Container 3 - App Server
pct create 102 "$CONTAINER_OS_TEMPLATE" \
--hostname app1 \
--memory 2048 \
--cores 2 \
--rootfs local-lvm:30 \
--net0 name=eth0,bridge=vmbr0,ip=dhcp \
--unprivileged 1
```
## Step 5: Start Containers
```bash
pct start 100
pct start 101
pct start 102
```
## Benefits
**One template, unlimited containers** - Download once, deploy many times
**Storage efficient** - Template is reused, only differences are stored
**Consistent base** - All containers start from the same clean OS
**Easy updates** - Update template, all new containers get updates
**Fast deployment** - No need to download template for each container
## Your Current Setup
Your deployment scripts already use this pattern! Check:
- `smom-dbis-138-proxmox/scripts/deployment/deploy-services.sh`
- `smom-dbis-138-proxmox/config/proxmox.conf.example`
They use: `CONTAINER_OS_TEMPLATE="${CONTAINER_OS_TEMPLATE:-local:vztmpl/debian-12-standard_12.2-1_amd64.tar.zst}"`
This means:
- If `CONTAINER_OS_TEMPLATE` is set, use it
- Otherwise, default to Debian 12 standard template
## Next Steps
1. **Set your template** in your config file
2. **Download it once**: `pveam download local debian-12-standard_12.2-1_amd64.tar.zst`
3. **Deploy containers** using your deployment scripts - they'll automatically use the template!