mirror of
https://github.com/Xe/furry-happiness
synced 2024-12-22 18:57:03 +00:00
move to slirp from debian repo
This commit is contained in:
parent
3ddc4f0046
commit
6d4b5389b8
13
Dockerfile
13
Dockerfile
@ -17,9 +17,10 @@ RUN apt-get update \
|
|||||||
&& cd .. \
|
&& cd .. \
|
||||||
&& rm -rf ${LINUX_VERSION}
|
&& rm -rf ${LINUX_VERSION}
|
||||||
|
|
||||||
FROM xena/alpine
|
FROM debian:testing-slim
|
||||||
|
|
||||||
ADD https://xena.greedo.xeserv.us/files/slirp /slirp
|
# Add slirp
|
||||||
|
RUN apt-get update && apt-get install --no-install-recommends -y slirp wget && rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
# Add Tini
|
# Add Tini
|
||||||
ENV TINI_VERSION v0.19.0
|
ENV TINI_VERSION v0.19.0
|
||||||
@ -30,8 +31,10 @@ RUN wget -O - http://dl-cdn.alpinelinux.org/alpine/v3.12/releases/x86_64/alpine-
|
|||||||
|
|
||||||
COPY --from=build /linux /linux
|
COPY --from=build /linux /linux
|
||||||
COPY init.sh /chroot/init.sh
|
COPY init.sh /chroot/init.sh
|
||||||
COPY resolv.conf /chroot/etc/resolv.conf
|
|
||||||
RUN chmod +x /linux /slirp /chroot/tini
|
RUN chmod +x /linux /chroot/tini && echo "nameserver 10.0.2.3" > /chroot/etc/resolv.conf
|
||||||
|
|
||||||
COPY runlinux.sh /runlinux.sh
|
COPY runlinux.sh /runlinux.sh
|
||||||
CMD /runlinux.sh
|
|
||||||
|
ENTRYPOINT [ "/runlinux.sh" ]
|
||||||
|
|
||||||
|
8
init.sh
8
init.sh
@ -2,11 +2,11 @@
|
|||||||
|
|
||||||
mount -t proc proc proc/
|
mount -t proc proc proc/
|
||||||
mount -t sysfs sys sys/
|
mount -t sysfs sys sys/
|
||||||
ifconfig eth0 10.0.2.14 netmask 255.255.255.240 broadcast 10.0.2.15
|
ip link set eth0 up
|
||||||
route add default gw 10.0.2.2
|
ip address add 10.0.2.15/24 dev eth0
|
||||||
|
ip route add default via 10.0.2.2
|
||||||
|
|
||||||
reset
|
|
||||||
uname -av
|
uname -av
|
||||||
echo "networking set up"
|
echo "networking set up"
|
||||||
|
|
||||||
exec /tini /bin/sh
|
exec /tini /bin/ash -- -i
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
nameserver 1.1.1.1
|
|
||||||
nameserver 8.8.8.8
|
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
export TMP=/chroot
|
export TMP=/chroot
|
||||||
exec /chroot/tini /linux root=/dev/root rootflags=/chroot rootfstype=hostfs rw mem=128M udb0=alpine-root verbose eth0=slirp,,/slirp init=/init.sh
|
exec /chroot/tini /linux root=/dev/root rootflags=/chroot rootfstype=hostfs rw mem=128M udb0=alpine-root verbose eth0=slirp,,slirp-fullbolt init=/init.sh
|
||||||
|
Loading…
Reference in New Issue
Block a user