DartSteven Posted 15 hours ago Posted 15 hours ago Hello Friends! I’m excited to share an alternative method for testing HexOS using QEMU via Docker. This approach not only simplifies the setup but also gives you flexibility to create a virtual environment tailored to your needs. To get you started, I’ve included: 1. My docker-compose.yaml file as a reference. 2. A mini script for creating a virtual network using a macvlan. Using a macvlan provides an added layer of security by isolating your virtual machines on a dedicated network segment, simulating a real-world environment. If you prefer, you can also assign specific MAC addresses and IPv4 addresses to your containers for finer control. However, if you’d like to keep things simpler, you can use Docker normally without setting up a macvlan. Just remember to remove the macvlan network configuration from the setup. I highly recommend using a macvlan for enhanced security and network segmentation, but the choice is yours! A huge thank you to the amazing HexOS community for making this project what it is. I hope this helps you explore HexOS more effectively. Let me know if you have any questions, feedback, or suggestions! services: qemu: container_name: HexOS image: qemux/qemu-docker privileged: true deploy: resources: limits: cpus: '4' memory: 8GB reservations: cpus: '2' memory: 4GB mac_address: xx:xx:xx:xx:xx:xx networks: vlan: ipv4_address: 192.168.xx.xx environment: DISK_SIZE: "20G" DISK_FMT: "qcow2" RAM_SIZE: "8G" CPU_CORES: "4" DISK2_SIZE: "32G" DISK3_SIZE: "32G" volumes: - /media/ssd/iso/ISO-OS/TrueNAS-SCALE-24.10.0-HexOS.iso:/boot.iso - /media/ssd/iso/OS/HexOS:/storage - /media/ssd/iso/OS/HexOS/disk1:/storage2 - /media/ssd/iso/OS/HexOS/disk2:/storage3 devices: - /dev/kvm # - /dev/bus/usb cap_add: - NET_ADMIN ports: - 8006:8006 stop_grace_period: 2m restart: unless-stopped networks: vlan: external: true For this method, all credit goes to the amazing repository qemus/qemu-docker, where you can find more detailed information and resources. For MacVlan: docker network create -d macvlan \ --subnet=192.168.xx.0/24 \ --gateway=192.168.xx.1 \ --ip-range=192.168.xx.0/28 \ -o parent=eno1 \ --aux-address="myserver=192.168.xx.xx" \ vlan Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.