fix: Dockerfile make buildable

This commit is contained in:
sim1222 2025-03-29 21:40:32 +09:00
parent 4459548fb3
commit ab287a2b69
Signed by: sim1222
GPG Key ID: D1AE30E316E44E5D
2 changed files with 29 additions and 3 deletions

View File

@ -1,10 +1,26 @@
FROM ubuntu:latest AS builder
WORKDIR /app
RUN apt update && \
apt install aria2 lsb-release wget software-properties-common gnupg unzip build-essential cmake -y
RUN bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)"
RUN aria2c -o android-ndk-r23b-linux.zip https://dl.google.com/android/repository/android-ndk-r23b-linux.zip
RUN unzip -q -d ~ android-ndk-r23b-linux.zip
COPY . /app
RUN mkdir /app/build && cd /app/build && cmake .. && make
FROM ubuntu:latest
WORKDIR /app
#COPY --from=builder /app /app
COPY . /app
COPY --from=builder /app/rootfs/ /app/rootfs/
COPY --from=builder /app/wrapper /app/
ENV args ""
CMD ["bash", "-c", "./wrapper ${args}"]
EXPOSE 10020 20020
EXPOSE 10020 10020

10
compose.yaml Normal file
View File

@ -0,0 +1,10 @@
services:
wrapper:
image: sim1222/wrapper:latest
build: .
volumes:
- ./rootfs/data:/app/rootfs/data
ports:
- 10020:10020
environment:
- args="-H 0.0.0.0"