Chuyển đến nội dung
Skillpedia
Triển khai và đám mây (DevOps)5.4k · #14963

azldev-image

Skill này làm gì

Skill này giải thích cách build và kiểm thử image hệ thống với azldev, dùng định nghĩa KIWI. Nó dành cho lập trình viên tạo image container hoặc máy ảo trong một bản phân phối azldev.

Khi nào nên dùng

  • ✓Khi bạn cần build một image container hoặc máy ảo từ các gói đã build.
  • ✓Khi bạn muốn khởi động một image đã build trong một máy ảo thử nghiệm.
  • ✓Khi bạn cần đăng ký hoặc thay đổi cài đặt của một image trong cấu hình.

Liên kết skill

https://github.com/microsoft/azurelinux/blob/4.0/.agents/skills/azldev-image/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/microsoft/azurelinux/blob/4.0/.agents/skills/azldev-image/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Bạn có thể build image container-base trong dự án azldev của chúng tôi và khởi động nó trong một máy ảo thử nghiệm không?”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Agent dùng các lệnh liệt kê, build, khởi động và kiểm thử image, với image được định nghĩa trong cấu hình. Nó kiểm tra các cờ của phiên bản công cụ đã cài trước khi chạy.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Build and boot images

An image assembles built RPMs into a deliverable — a container or a bootable VM. azldev drives the build from a kiwi-ng definition; the .kiwi file itself is upstream KIWI NG (docs) and azldev does not own its schema.

Commands

Images are selected by their name as a positional argument (not -p).

Task Command
List images azldev image list
Build an image (kiwi-ng) azldev image build <name>
Boot an image in a QEMU VM azldev image boot <name>
Run an image's tests azldev image test <name>
Customize a pre-built image azldev image customize

azldev image build takes --local-repo / --remote-repo to add package sources and --arch to target an architecture. When the selected distro version defines kiwi-config-override, azldev passes it to KIWI with --config. These top-level overrides have highest precedence. azldev image boot takes a built image name, or an explicit --image-path / --iso. Confirm current flags with azldev image <command> --help (there are more subcommands, e.g. inject-files).

Registering an image

Images are declared under [images.<name>] (conventionally in an images.toml):

[images.container-base]
description = "Container base image"
definition = { type = "kiwi", path = "container-base/container-base.kiwi", profile = "core" }
architectures = ["x86_64", "aarch64"]

  [images.container-base.capabilities]
  container = true
  systemd = false

  [images.container-base.properties]
  openssl-fips-provider = "upstream"

  [images.container-base.tests]
  tests = [{ name = "smoke" }]
  • definition.type is kiwi (the only type today); path points at the .kiwi file; profile selects a kiwi profile (optional).
  • Boolean capabilities are tri-state flags describing the image — machine-bootable, container, systemd, runtime-package-management, wsl, installer-media, fips-enabled, and cvm. Set only the ones that apply.
  • properties is an extensible string-to-string metadata bag. For example, openssl-fips-provider = "upstream" records the image's provider policy without requiring azldev to define that property in its schema.
  • architectures = ["x86_64", "aarch64"] is optional; when unset or empty, the image is treated as unrestricted (all recognized architectures). Set it to restrict which architectures image build --arch allows for the image.
  • tests.tests lists the tests or test groups azldev image test runs locally. An image ref may also set sku-groups = ["<name>", ...] to fan a test or group out across the VM sizes of one or more [sku-groups.<name>] entries; that fan-out is done by external test orchestration, not by local azldev image test. Do not map sku-groups onto arbitrary LISA tests: LISA tests carry their own requirements and are skipped when the SKU does not meet them, so this is meaningful only for the special case of multi-SKU performance tests.
  • publish.channels lists the channels the image publishes to.

The kiwi definition

The .kiwi file is upstream KIWI NG XML — azldev does not own its schema. It selects the image type (container vs. VM), package lists, repositories, and boot configuration. See the KIWI NG documentation for the format and elements.

Generated by azldev docs agent; do not hand-edit.

Câu hỏi thường gặp

Định dạng nào định nghĩa image?

Image dùng các file định nghĩa KIWI NG, một định dạng upstream mà công cụ build từ đó.

Tôi có thể khởi động image mà không build lại không?

Có. Skill ghi rằng có thể khởi động tên image đã build hoặc một file image được chỉ định rõ.

Image được đăng ký ở đâu?

Image được khai báo trong cấu hình của dự án dưới một mục images, thường nằm trong một file images.

Chi tiết

Mô tả gốc của tác giả

Read this before building, booting, or configuring an azldev image. Explains the azldev image commands (list, build, boot, test, customize) and the [images.<name>] config (kiwi definition, capabilities, tests, publish); the kiwi XML format itself is upstream KIWI NG. Triggers include image build, image boot, kiwi, container image, VM image, images.toml.

repo: microsoft/azurelinux

Độ phổ biến

Sao GitHub
5.4k
Vị trí xếp hạng
#14963
Giấy phép
MIT
Cập nhật
2/11/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự