More work on the F-Droid Repo setup.
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
# Build a container which hosts Android apps through an F-Droid repository.
|
# Build a container which hosts Android apps through an F-Droid repository.
|
||||||
|
# https://f-droid.org/en/docs/Setup_an_F-Droid_App_Repo/
|
||||||
|
|
||||||
# Base Image #
|
# Base Image #
|
||||||
|
|
||||||
@@ -6,12 +7,32 @@ FROM debian:trixie-slim
|
|||||||
|
|
||||||
# Setup #
|
# Setup #
|
||||||
|
|
||||||
RUN mkdir -pv "$REPO/"
|
ARG REPO
|
||||||
|
ENV REPO="$REPO"
|
||||||
|
ARG WEBROOT
|
||||||
|
ENV WEBROOT="$WEBROOT"
|
||||||
|
|
||||||
|
USER root
|
||||||
|
RUN mkdir -pv "$REPO"
|
||||||
|
WORKDIR "$REPO"
|
||||||
|
|
||||||
# Install Packages#
|
# Install Packages#
|
||||||
|
# https://f-droid.org/en/docs/Installing_the_Server_and_Repo_Tools/#debianubuntumintetc
|
||||||
|
|
||||||
# TBD/TODO: get list of packages
|
RUN apt-get update && apt-get install sudo bash curl git vim nginx
|
||||||
RUN apt-get update && apt-get install bash curl fdroidserver
|
COPY files/debian-backports.sources /etc/apt/sources.list.d/
|
||||||
|
RUN apt-get update && apt-get install -t trixie-backports fdroidserver
|
||||||
|
|
||||||
|
# Generate F-Droid Repo #
|
||||||
|
|
||||||
|
|
||||||
|
# Publish? #
|
||||||
|
|
||||||
|
#TBD/TODO
|
||||||
|
|
||||||
|
# Configure F-Droid Repo #
|
||||||
|
|
||||||
|
RUN sed -i 's/TBD/TODO/g' TBD.cfg
|
||||||
|
|
||||||
# Download Files #
|
# Download Files #
|
||||||
|
|
||||||
@@ -39,11 +60,15 @@ RUN bash -c 'if [[ -n "$FILE17" ]]; then curl "$FILE17" "$REPO"/; fi'
|
|||||||
RUN bash -c 'if [[ -n "$FILE18" ]]; then curl "$FILE18" "$REPO"/; fi'
|
RUN bash -c 'if [[ -n "$FILE18" ]]; then curl "$FILE18" "$REPO"/; fi'
|
||||||
RUN bash -c 'if [[ -n "$FILE19" ]]; then curl "$FILE19" "$REPO"/; fi'
|
RUN bash -c 'if [[ -n "$FILE19" ]]; then curl "$FILE19" "$REPO"/; fi'
|
||||||
|
|
||||||
|
RUN bash -c 'cd "$REPO" && fdroid update'
|
||||||
|
|
||||||
|
# Publish Repo to Web Root #
|
||||||
|
|
||||||
|
#TBD/TODO
|
||||||
|
|
||||||
# Start Container #
|
# Start Container #
|
||||||
|
|
||||||
USER root
|
CMD sleep 5 \
|
||||||
WORKDIR "$REPO"
|
&& tail -F /var/mail/* & \
|
||||||
CMD cd "$REPO" && \
|
&& tail -F /var/log/nginx/* & \
|
||||||
fdroid update \
|
&& wait -n
|
||||||
&& tail -F /var/mail/mail & \
|
|
||||||
&& wait -n
|
|
||||||
|
|||||||
@@ -8,9 +8,13 @@ services:
|
|||||||
build:
|
build:
|
||||||
context: ./
|
context: ./
|
||||||
network: host
|
network: host
|
||||||
|
args:
|
||||||
|
WEBROOT: ${WEBROOT}
|
||||||
|
REPO: ${REPO}
|
||||||
restart: always
|
restart: always
|
||||||
environment:
|
environment:
|
||||||
- REPO=$REPO
|
- WEBROOT=/var/www/html
|
||||||
|
- REPO=/root/fdroid
|
||||||
- FILE0=$FILE0
|
- FILE0=$FILE0
|
||||||
- FILE1=$FILE1
|
- FILE1=$FILE1
|
||||||
- FILE2=$FILE2
|
- FILE2=$FILE2
|
||||||
@@ -32,7 +36,8 @@ services:
|
|||||||
- FILE18=$FILE18
|
- FILE18=$FILE18
|
||||||
- FILE19=$FILE19
|
- FILE19=$FILE19
|
||||||
volumes:
|
volumes:
|
||||||
- ../../Volumes/F-DroidRepo:$REPO
|
- ../../Volumes/F-DroidRepo/fdroid:/root/fdroid
|
||||||
|
- ../../Volumes/F-DroidRepo/nginx:/var/www/html
|
||||||
deploy:
|
deploy:
|
||||||
mode: global
|
mode: global
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
6
Config/F-DroidRepo/files/debian-backports.sources
Normal file
6
Config/F-DroidRepo/files/debian-backports.sources
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
Types: deb deb-src
|
||||||
|
URIs: http://deb.debian.org/debian
|
||||||
|
Suites: trixie-backports
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
Enabled: yes
|
||||||
Reference in New Issue
Block a user