1- FROM docker.io/debian:trixie-slim
1+ FROM docker.io/sirrgb/dockdroid-base:latest
22
33# User
44ARG userid=1000
55ARG groupid=1000
6- ARG username=droid
7- ENV USER="${username}"
86
9- # Dirs
7+ # Directories
108ARG ROOT_DIR=/droid_workdir
119ENV SCRIPT_DIR="${ROOT_DIR}" /scripts
12- ENV ROM_DIR="${ROOT_DIR}" /src/Los15
10+ ENV ROM_DIR=''
1311ENV KEYS_DIR="${ROOT_DIR}" /keys
14- ENV BIN_DIR="${ROOT_DIR}" /bin
1512ENV LOGS_DIR="${ROOT_DIR}" /logs
1613
17- # Switch to Root for Setup
1814USER root
1915
20- # Android build dependencies
21- RUN DEBIAN_FRONTEND=noninteractive apt-get update -qq && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
22- bc \
23- bison \
24- build-essential \
25- ca-certificates \
26- ccache \
27- curl \
28- flex \
29- g++-multilib \
30- gcc-multilib \
31- git \
32- git-lfs \
33- gnupg \
34- gperf \
35- imagemagick \
36- lib32readline-dev \
37- lib32z1-dev \
38- libelf-dev \
39- libncurses6 \
40- libsdl1.2-dev \
41- libssl-dev \
42- libxml2 \
43- libxml2-utils \
44- lz4 \
45- lzop \
46- pngcrush \
47- python3 \
48- python-is-python3 \
49- rsync \
50- schedtool \
51- ssh \
52- squashfs-tools \
53- xsltproc \
54- zip \
55- zlib1g-dev \
56- # Python
57- libbz2-dev \
58- liblzma-dev \
59- libsqlite3-dev \
60- libreadline-dev \
61- # Automation
62- file \
63- jq \
64- unzip
65-
66- RUN rm --recursive /var/lib/apt/lists /var/cache/apt/archives
67-
68- # Symlink libncurses for compatibility
69- RUN ln -s /usr/lib/x86_64-linux-gnu/libncurses.so.6 /usr/lib/x86_64-linux-gnu/libncurses.so.5
70- RUN ln -s /usr/lib/x86_64-linux-gnu/libtinfo.so.6 /usr/lib/x86_64-linux-gnu/libtinfo.so.5
71-
7216# Create dirs and copy scripts
73- RUN mkdir -p "${SCRIPT_DIR}" "${BIN_DIR}" "${KEYS_DIR }"
17+ RUN mkdir --parents "${SCRIPT_DIR}"
7418COPY scripts/ "${SCRIPT_DIR}" /
19+ COPY py-utils/ "${BIN_DIR}" /
7520
7621# Set up user and work directories
77- RUN groupadd -g "${groupid}" "${username}" \
78- && useradd -m -s /bin/bash -u "${userid}" -g "${groupid}" "${username}" -d "${ROOT_DIR}"
79- RUN chown -R "${userid}" :"${groupid}" "${ROOT_DIR}" && chmod -R ug+srw "${ROOT_DIR}"
22+ RUN chown --recursive "${userid}" :"${groupid}" "${ROOT_DIR}" && chmod --recursive u+srw "${ROOT_DIR}"
8023
8124# Switch to user for execution
82- USER "${username}"
83-
84- # Install and verify repo
85- RUN gpg --recv-key 8BB9AD793E8E6153AF0F9A4416530D5E920F5C65
86- RUN curl -o "${BIN_DIR}" /repo https://storage.googleapis.com/git-repo-downloads/repo
87- RUN curl https://storage.googleapis.com/git-repo-downloads/repo.asc | gpg --verify - "${BIN_DIR}" /repo
88-
89- # Provide make_key to create signing keys
90- RUN curl https://raw.githubusercontent.com/LineageOS/android_development/refs/heads/lineage-23.0/tools/make_key > "${BIN_DIR}" /make_key
91-
92- # Patch for longer key size and drop input
93- RUN sed -i "/read -p \" Enter password for '\$ 1' (blank for none\; password will be visible): \" \\\/ d" "${BIN_DIR}" /make_key
94- RUN sed -i "s/ password/password=\"\" /g; s/echo; exit 1' EXIT INT QUIT/' EXIT/g; s/2048/4096/g" "${BIN_DIR}" /make_key
25+ USER "${USER}"
9526
9627# Make scripts executable
97- RUN chmod -R 500 "${BIN_DIR }" "${SCRIPT_DIR }"
28+ RUN chmod --recursive 500 "${SCRIPT_DIR }" "${BIN_DIR }"
9829
9930# ROM variables
10031ENV LOCAL_MANIFEST=''
@@ -110,19 +41,25 @@ ENV LUNCH_PREFIX_FALLBACK=''
11041ENV ROM_PREFIX_FALLBACK=''
11142ENV ROM_VERSION_FALLBACK=''
11243ENV ROM_OTA_BRANCH_FALLBACK=''
44+ ENV RELEASETOOL_EXTRA_FLAGS=''
11345
11446# Extra variables
11547ENV CCACHE_SIZE=40
11648ENV OTA_REPO_URL=''
11749ENV KEYS_SUBJECT=
'/C=US/ST=California/L=Mountain View/O=Android/OU=Android/CN=Android/[email protected] ' 118- ENV TIME_ZONE=" UTC"
50+ ENV TIME_ZONE=' UTC'
11951ENV REPOPICK_PICKS=''
12052ENV REPOPICK_TOPICS=''
53+ ENV REPOPICK_PULLS=''
54+ ENV DEBUG=''
12155
12256# Authentification
12357ENV TELEGRAM_TOKEN=''
12458ENV GITHUB_TOKEN=''
12559ENV SF_USER=''
12660ENV SF_RELEASES_REPO=''
61+ ENV SSH_USER=''
62+ ENV SSH_UPLOAD_URL=''
63+ ENV SSH_DOWNLOAD_URL=''
12764
12865ENTRYPOINT ["/bin/bash" , "-c" , "${SCRIPT_DIR}/init.sh" ]
0 commit comments