From 54b0e940df30010d3bda8feb16db3cfccb9f46cc Mon Sep 17 00:00:00 2001 From: Rustam Gilyazov <16064414+rusq@users.noreply.github.com> Date: Sun, 9 Apr 2023 11:46:23 +1000 Subject: [PATCH] docker compose and docker --- .gitignore | 1 + Dockerfile | 31 +++++++++++++++++++++++++++++++ docker-compose.yaml | 11 +++++++++++ 3 files changed, 43 insertions(+) create mode 100644 Dockerfile create mode 100644 docker-compose.yaml diff --git a/.gitignore b/.gitignore index db6a692..2b4a112 100644 --- a/.gitignore +++ b/.gitignore @@ -25,3 +25,4 @@ compile_commands.json gunzip gzip zcat +*~ diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c1386a5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,31 @@ +FROM debian:bookworm-slim as stage + +RUN apt-get update + +RUN apt-get install -y \ + wget \ + build-essential \ + gcc-multilib \ + lib32ncurses-dev \ + cpio \ + && rm -rf /var/lib/apt/lists/* + +WORKDIR /build + +COPY . . + +RUN wget https://archive.org/download/123-unix/123UNIX1.IMG \ + && wget https://archive.org/download/123-unix/123UNIX2.IMG \ + && wget https://archive.org/download/123-unix/123UNIX3.IMG \ + && wget https://archive.org/download/123-unix/123UNIX4.IMG \ + && wget https://archive.org/download/123-unix/123UNIX5.IMG + +RUN ./binutils.sh \ + && ./extract.sh + +RUN make install \ + && cd / \ + && rm -rf /build + +WORKDIR /work + diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..691b3ae --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,11 @@ +version: "3.9" + +services: + 123r3: + build: + context: . + volumes: + - .:/work + stdin_open: true + tty: true + command: "123"