2025-03-22 10:28:14 +01:00
# Linux Image Manager 🖥️🛠️
2025-03-12 20:52:47 +01:00
2025-03-22 10:28:14 +01:00
[](https://github.com/sponsors/kevinveenbirkenbach) [](https://www.patreon.com/c/kevinveenbirkenbach) [](https://buymeacoffee.com/kevinveenbirkenbach) [](https://s.veen.world/paypaldonate)
2019-09-30 14:47:48 +02:00
2025-03-04 19:59:47 +01:00
[](./LICENSE.txt) [](https://github.com/kevinveenbirkenbach/linux-image-manager/stargazers)
2020-05-03 22:14:18 +02:00
2025-03-22 10:28:14 +01:00
Linux Image Manager (lim) is a powerful collection of shell scripts for downloading, configuring, and managing Linux images. Whether you're setting up encrypted storage, configuring a virtual Btrfs RAID1, performing backups, or chrooting into an image, this tool makes Linux image administration simple and efficient. 🚀
> **Note:** In this project, `lim` is an alias for the **main.py** wrapper script which orchestrates the execution of the various shell scripts.
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
## Features ✨
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
- **Image Download & Setup:** Automatically download and prepare Linux distributions.
- **Encrypted Storage:** Configure LUKS encryption for secure image management.
- **Virtual RAID1:** Easily set up virtual Btrfs RAID1 for data redundancy.
2025-03-22 10:28:14 +01:00
- **Backup & Restore:** Create image backups from devices using dd.
- **Chroot Environment:** Easily enter a chroot shell to maintain or modify Linux images.
2025-03-04 19:59:47 +01:00
- **Automated Procedures:** Simplify partitioning, formatting, mounting, and more.
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
## Installation 📦
2023-05-02 13:21:46 +02:00
2025-03-22 10:28:14 +01:00
Install Linux Image Manager quickly using [Kevin's Package Manager ](https://github.com/kevinveenbirkenbach/package-manager ) under the alias `lim` . Just run:
2020-05-02 11:46:39 +02:00
```bash
2025-03-04 19:59:47 +01:00
package-manager install lim
2020-05-02 11:46:39 +02:00
```
2023-05-02 13:21:46 +02:00
2025-03-22 10:28:14 +01:00
This command makes Linux Image Manager globally available as `lim` in your terminal. The `lim` alias points to the **main.py ** wrapper script.
2025-03-04 19:59:47 +01:00
## Usage ⚙️
2024-07-21 15:34:05 +02:00
2025-03-22 10:28:14 +01:00
The **main.py ** wrapper provides a unified interface to run the different shell scripts included in this project. It supports various script types and allows you to pass additional parameters. The built-in `--help` option displays detailed usage information.
2025-03-04 19:59:47 +01:00
2025-03-22 10:28:14 +01:00
### Available Script Types
2024-07-21 15:34:05 +02:00
2025-03-22 10:28:14 +01:00
- **Image Setup (`--type image` ):**
Executes the Linux image setup located at `scripts/image/setup.sh` . This setup:
- Creates partitions and formats them.
- Transfers the Linux image file to the device.
- Configures boot and root partitions.
2024-07-21 15:34:05 +02:00
2025-03-22 10:28:14 +01:00
- **Single Drive Encryption Setup (`--type single` ):**
Executes the single-drive encryption setup from `scripts/encryption/storage/single_drive/setup.sh` . This setup:
- Sets up disk encryption using LUKS on one drive.
- Configures a Btrfs file system for secure storage.
2024-07-21 15:34:05 +02:00
2025-03-22 10:28:14 +01:00
- **RAID1 Encryption Setup (`--type raid1` ):**
Executes the RAID1 encryption setup found at `scripts/encryption/storage/raid1/setup.sh` . This setup:
- Configures a virtual RAID1 with two drives.
- Uses LUKS encryption and a Btrfs RAID1 file system for redundancy.
- **Backup Image Setup (`--type backup` ):**
Executes the backup image setup located at `scripts/image/backup.sh` . This setup:
- Creates an image backup from a memory device to a file.
- Uses `dd` to transfer the image from the specified device to an image file.
- **Chroot Environment Setup (`--type chroot` ):**
Executes the chroot setup from `scripts/image/chroot.sh` . This setup:
- Mounts partitions and configures the chroot environment for a Linux image.
- Provides a shell within the Linux image for system maintenance.
### Command-Line Options
- **`--type` **
* * (Required)** Choose the type of script to execute. Options include: `image` , `single` , `raid1` , `backup` , and `chroot` .
- **`--extra` **
* * (Optional)** Pass any extra parameters directly to the selected shell script.
- **`--auto-confirm` **
* * (Optional)** Automatically bypass the confirmation prompt before executing the selected script.
- **`--help` **
* * (Optional)** Displays detailed help information about the command-line options and usage of the wrapper. Simply run:
```bash
lim --help
```
to view the complete help message.
### Example Commands
- **Display Help:**
```bash
lim --help
```
- **Show Information About the Image Setup:**
```bash
lim --type image --info
```
- **Execute the Linux Image Setup (with extra parameters):**
```bash
lim --type image --extra --some-option value
```
- **Run the Single Drive Encryption Setup without a confirmation prompt:**
```bash
lim --type single --auto-confirm
```
- **Execute the RAID1 Encryption Setup:**
```bash
lim --type raid1
```
- **Perform a Backup of an Image:**
```bash
lim --type backup
```
- **Enter a Chroot Environment for a Linux Image:**
```bash
lim --type chroot
```
2024-07-21 22:44:39 +02:00
2025-03-22 10:28:14 +01:00
For additional details on each script and further configuration options, please refer to the `scripts/` and `configuration/` directories.
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
## Configuration & Customization 🔧
2020-09-30 17:07:51 +02:00
2025-03-04 19:59:47 +01:00
Customize your environment in the `configuration/` folder:
2025-03-22 10:28:14 +01:00
- **General Packages:** Contains common packages for all setup scripts.
- **Server LUKS Packages:** Contains packages needed for setting up LUKS encryption on servers.
2020-09-30 17:07:51 +02:00
2025-03-04 19:59:47 +01:00
## License 📜
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
This project is licensed under the GNU General Public License Version 3. See the [LICENSE.txt ](./LICENSE.txt ) file for details.
2020-09-30 17:07:51 +02:00
2025-03-04 19:59:47 +01:00
## Contact & Support 💬
2020-05-02 11:46:39 +02:00
2025-03-04 19:59:47 +01:00
- **Author:** Kevin Veen-Birkenbach
- **Email:** [kevin@veen.world ](mailto:kevin@veen.world )
- **Website:** [https://www.veen.world/ ](https://www.veen.world/ )
2023-05-02 13:21:46 +02:00
2025-03-04 19:59:47 +01:00
Feel free to contribute, report issues, or get in touch. Happy Linux managing! 😊
2025-03-22 10:28:14 +01:00
```