diff --git a/Dockerfile b/Dockerfile index 9f1af5c..b0a172b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM amd64/debian:bullseye +FROM amd64/debian:stable LABEL com.iximiuz-project="docker-to-linux" RUN apt-get -y update RUN apt-get -y install extlinux fdisk diff --git a/Makefile b/Makefile index e68a65e..9559483 100644 --- a/Makefile +++ b/Makefile @@ -3,6 +3,7 @@ COL_GRN="\033[0;32m" COL_END="\033[0m" REPO=docker-to-linux +BRIDGE=`docker network inspect --format='{{json .Options}}' bridge | python -c 'import json,sys;obj=json.load(sys.stdin);print(obj["com.docker.network.bridge.name"])'` .PHONY: debian: debian.img @@ -93,3 +94,10 @@ clean-docker-images: echo "";\ fi +net: + ip tuntap add dev tap0 mod tap + ip link set dev tap0 master ${BRIDGE} + ip link set tap0 up + +run-qemu-with-net: + qemu-system-x86_64 -drive file=linux.img,index=0,media=disk,format=raw -m 4096 -netdev tap,id=mynet0,ifname=tap0,script=no,downscript=no -device e1000,netdev=mynet0,mac=52:55:00:d1:55:01 diff --git a/README.md b/README.md index 90d50c3..260624a 100644 --- a/README.md +++ b/README.md @@ -41,9 +41,30 @@ Check out `Makefile` for more details or read my article on