jstorcli-yatc-jetice-ops
Use when operating jstorcli with yatc and jetice/jetlake workflows, especially for VM lifecycle, image prep, deployment checks, and command lookup without hardcoded paths.
SKILL.mdskills/jstorcli-yatc-jetice-ops/SKILL.md
GitHubjstorcli + yatc + jetice/jetlake Ops
Overview
This skill is the first command reference for deployment and validation work involving jstorcli, yatc, jetice-env, and JetLake planes/profiles.
Use dynamic path discovery first. Do not hardcode project directories.
Environment Discovery
# Project root (prefer current repo root)
export YATC_ROOT="${YATC_ROOT:-$(git rev-parse --show-toplevel 2>/dev/null || pwd)}"
# Compose directory (first compose.yaml under repo, override when needed)
export YATC_COMPOSE_DIR="${YATC_COMPOSE_DIR:-$(find "$YATC_ROOT" -maxdepth 3 -type f -name compose.yaml -print -quit | xargs -r dirname)}"
# jstorcli source root (contains src/jstorcli/__main__.py)
export JSTORCLI_ROOT="${JSTORCLI_ROOT:-$(find "$YATC_ROOT" -type f -path '*/jstorcli/src/jstorcli/__main__.py' -print -quit | sed 's#/src/jstorcli/__main__.py##')}"
export JSTORCLI_SRC="${JSTORCLI_SRC:-$JSTORCLI_ROOT/src}"
# Optional image URL input for local mirror/download
export YATC_IMAGE_URL="${YATC_IMAGE_URL:-http://factory.jetio.net/artifactory/packer-os-images/jetice/ubuntu/ubuntu-22.04.5-jetice-uefi-2507.2-2-amd64-20250724.qcow2}"
yatc Build/Install/Deploy Flow
# 1) Build latest wheel
cd "$YATC_ROOT"
uv build
# 2) Install latest wheel to system python
sudo uv pip install --system "$(ls -t dist/*.whl | head -n 1)"
# 3) Register local images manifest (edit images.yaml path first)
sudo yatc images register -m "$YATC_ROOT/images.yaml"
# 4) Pull configured image name from images.yaml
sudo yatc pull ubuntu-22045-jetice
# 5) Start compose VM group
sudo yatc compose up --provider qemu --dir "$YATC_COMPOSE_DIR"
# 6) Check VM/IP
sudo yatc ps
# 7) Stop and remove compose resources when done
sudo yatc compose down --provider qemu --dir "$YATC_COMPOSE_DIR"
sudo yatc compose rm --dir "$YATC_COMPOSE_DIR"
jstorcli Current Command Surface
Source of truth:
src/jstorcli/__main__.py- each sub-CLI parser file
Top-level multiplexer:
jstorcli drbd(drbd-cli,drbd_cli)jstorcli lvm(lvm-pool,lvm_poolfor legacy)jstorcli jetlakejstorcli hagroupjstorcli zfsjstorcli bash-completion(bash-completetionalias exists in code)
DRBD
statusprepareprocessdeleteadjustprimarysecondary
LVM
Group pool:
discoverdefinecreatedeletelistshow
Group lv:
createresizedeleterenamesnapshotrestorerollback
Legacy lvm-pool also exposes:
discover,define,create,delete,list,showlv-create,lv-resize,lv-delete,lv-renamelv-snapshot,lv-restore,lv-rollback
JetLake
Group profile:
definevalidatecreatedestroyundef
Group plane:
definecreatedestroylistundef
HAGroup
defineupdatecreategetlistdeleteresolve
ZFS
Group pool:
listinfocreatedelete
Group volume:
listcreateresizedeleterename
Group snapshot:
createdeleteclonerollback
Group profile:
definelistshowvalidateapplyinit
Also:
sendreceive
jetice-env Runtime Commands (inside VM)
jetice-env command family:
checkpullconfigreconfinitcomposeprepverifydeploystateremove
Common VM validation:
cloud-init status
cd /opt/jetice-vtl
./jetice_s3gw_acceptance jetice s3gw http://0.0.0.0:9000
Recovery/Reset Operations
# Host key cleanup when VM IP changes
ssh-keygen -f ~/.ssh/known_hosts -R "192.168.122.2"
# Last-resort cleanup (destructive)
sudo rm -rf /opt/yatc/compute
Maintenance: Keep This Skill Updated
When jstorcli changes, refresh this skill in the same commit:
- Re-check parser definitions in:
src/jstorcli/__main__.pysrc/jstorcli/*_cli.py
- Re-run help snapshots:
cd "$JSTORCLI_ROOT"
export PYTHONPATH="$JSTORCLI_SRC"
python3 -m jstorcli --help
python3 -m jstorcli.drbd_cli --help
python3 -m jstorcli.lvm_cli --help
python3 -m jstorcli.lvm_pool_cli --help
python3 -m jstorcli.jetlake_cli --help
python3 -m jstorcli.hagroup_cli --help
python3 -m jstorcli.zfs_cli --help
- Update this skill's command lists when any subcommand is added/removed/renamed.
- Keep path handling dynamic (
YATC_ROOT,YATC_COMPOSE_DIR,JSTORCLI_ROOT) and avoid fixed absolute paths.