# KBuilder **Repository Path**: anolis/kbuilder ## Basic Information - **Project Name**: KBuilder - **Description**: 通过对多种开源项目/工具的封装、改进,同时增加了一些功能,实现各种常见镜像自定义打包的自动化,简化使用和操作步骤,提升效率和正确率,为Anolis和KOS的使用人员提供常见镜像类型的制作、打包工具。 支持的镜像种类:ISO 、liveISO 、qcow2、容器、可作为ramfs使用的initrd。 - **Primary Language**: Shell - **License**: MulanPSL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 10 - **Forks**: 2 - **Created**: 2023-07-04 - **Last Updated**: 2024-03-28 ## Categories & Tags **Categories**: ci **Tags**: None ## README # KBuilder #### Description Through the packaging and improvement of a variety of open source projects/tools, and the addition of some functions, to achieve a variety of common image custom packaging automation, simplify the use and operation steps, improve efficiency and correct rate, for Anolis and KOS users to provide common image types of production, packaging tools. Supported image types: ISO, liveISO, qcow2, container, initrd can be used as ramfs. #### Software Architecture ``` ISO | liveISO | initrd | qcow2 | docker ------------------------------------------------ pungi | lorax | anaconda | Self developed code ------------------------------------------------ KOS yum repo | Anolis yum repo ``` #### Installation 1. sh setup.sh #### Instructions 1. qcow2 set param in qcow2.conf; `sh create-qcow2.sh` 2. docker To create a default base image, you can use the following command: `sh create docker.sh` To create a base image and add two software packages, vim enhanced and dhcp server, you can use the following command: `sh create docker sh - p vim enhanced - p dhcp server` To create a base image and add group: file server, as well as Python 36 and Python 38, you can use the following command: `sh create docker.sh - g file server - g python36- g python38` 3. liveISO Configure modifiable parameters in livemedia.conf; ADD_ PACKAGES can add RPM packages installed in Squashfs.img of live ISO ADD_ GROUPS can increase the RPM group installed in Squashfs.img of live ISO ADD_ FILES can add the specified file/folder to the specified location in Squashfs.img of live ISO, Location can be achieved through ADD_ FILES_ TARGET settings Finally, execute `sh create-liveiso.sh` 4. initrd Configure modifiable parameters in create-initrd-ramos-from-cur-os.conf: ADD_ DRIVERS can add kernel modules installed in initrd OMIT_ DRIVERS can exclude certain kernel modules from initrd INSTALL_ PROG can add user mode command tools installed in initrd INCLUDE_ FILE_ DIRECTORY * can add specified files/folders to initrd Finally, execute `sh create-initrd-ramos-from-cur-os.sh` #### Contribution 1. Fork the repository 2. Create Feat_xxx branch 3. Commit your code 4. Create Pull Request #### Gitee Feature 1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md 2. Gitee blog [blog.gitee.com](https://blog.gitee.com) 3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore) 4. The most valuable open source project [GVP](https://gitee.com/gvp) 5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help) 6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)