Skip to content

Commit

Permalink
converted armui to Phusion runsv daemon
Browse files Browse the repository at this point in the history
  • Loading branch information
shitwolfymakes committed May 18, 2022
1 parent c76a4e8 commit a42657f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
# setup default directories and configs
FROM shitwolfymakes/arm-dependencies AS base

# Setup folders and fstab
RUN \
mkdir -m 0777 -p /home/arm /home/arm/config /mnt/dev/sr0 /mnt/dev/sr1 /mnt/dev/sr2 /mnt/dev/sr3 && \
echo "/dev/sr0 /mnt/dev/sr0 udf,iso9660 users,noauto,exec,utf8,ro 0 0" >> /etc/fstab && \
echo "/dev/sr1 /mnt/dev/sr1 udf,iso9660 users,noauto,exec,utf8,ro 0 0" >> /etc/fstab && \
echo "/dev/sr2 /mnt/dev/sr2 udf,iso9660 users,noauto,exec,utf8,ro 0 0" >> /etc/fstab && \
echo "/dev/sr3 /mnt/dev/sr3 udf,iso9660 users,noauto,exec,utf8,ro 0 0" >> /etc/fstab

# Copy over source code
COPY . /opt/arm/
RUN rm -rf /opt/arm/venv

Expand All @@ -18,11 +20,13 @@ RUN rm -rf /etc/service/sshd /etc/my_init.d/00_regen_ssh_host_keys.sh
# Add ARMui service
RUN mkdir /etc/service/armui
COPY ./scripts/docker/runsv/armui.sh /etc/service/armui/run
RUN chmod +x /etc/service/armui/run

# Create our startup scripts
RUN mkdir -p /etc/my_init.d
COPY ./scripts/docker/runit/arm_user_setup.sh /etc/my_init.d/arm_user_setup.sh
COPY ./scripts/docker/runit/entrypoint.sh /etc/my_init.d/entrypoint.sh
COPY ./scripts/docker/runit/start_udev.sh /etc/my_init.d/start_udev.sh
COPY ./scripts/docker/runit/docker-entrypoint.sh /etc/my_init.d/docker-entrypoint.sh
RUN chmod +x /etc/my_init.d/*.sh

# We need to use a modified udev
Expand All @@ -34,10 +38,6 @@ RUN ln -sv /opt/arm/setup/51-docker-arm.rules /lib/udev/rules.d/

EXPOSE 8080

VOLUME /home/arm/Music
VOLUME /home/arm/logs
VOLUME /home/arm/media
VOLUME /etc/arm/config

###########################################################
# Final image pushed for use
Expand Down
2 changes: 1 addition & 1 deletion scripts/docker/runsv/armui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

echo "Starting web ui"
chmod +x /opt/arm/arm/runui.py
exec /bin/python3 /opt/arm/arm/runui.py
exec /sbin/setuser arm /bin/python3 /opt/arm/arm/runui.py

0 comments on commit a42657f

Please sign in to comment.