Use dotnet instead of mono and rebase to Alpine (#52)

This commit is contained in:
Adam 2022-03-29 22:06:29 +01:00 committed by GitHub
parent f0760a8e47
commit c5ff579706
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 59 additions and 54 deletions

View File

@ -1,4 +1,4 @@
FROM ghcr.io/linuxserver/baseimage-ubuntu:focal
FROM ghcr.io/linuxserver/baseimage-alpine:3.15
# set version label
ARG BUILD_DATE
@ -10,26 +10,22 @@ LABEL maintainer="saarg"
ARG WEBGRAB_VER
# environment variables.
ARG DEBIAN_FRONTEND="noninteractive"
ENV HOME /config
RUN \
echo "**** add mono repository ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
echo "deb https://download.mono-project.com/repo/ubuntu focal main" | tee /etc/apt/sources.list.d/mono-official.list && \
echo "**** install packages ****" && \
apt-get update && \
apt-get install -y \
cron \
libmono-system-data4.0-cil \
libmono-system-net-http-webrequest4.0-cil \
libmono-system-web4.0-cil \
mono-devel \
mono-runtime \
apk -U --update --no-cache add \
bash \
curl \
icu-libs \
iputils \
unzip && \
echo "**** install dotnet sdk ****" && \
mkdir -p /app/dotnet && \
curl -o /tmp/dotnet-install.sh -L \
https://dot.net/v1/dotnet-install.sh && \
chmod +x /tmp/dotnet-install.sh && \
/tmp/dotnet-install.sh -c 5.0 --install-dir /app/dotnet --runtime dotnet && \
echo "**** install webgrabplus ****" && \
if [ -z "$WEBGRAB_VER" ]; then \
WEBGRAB_VER=$(curl -fsL http://webgrabplus.com/download/sw | grep -m1 /download/sw/v | sed 's|.*/download/sw/v\(.*\)">V.*|\1|'); \
@ -50,9 +46,7 @@ RUN \
unzip -q /tmp/ini.zip -d /defaults/ini/ && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
/var/lib/apt/lists/* \
/var/tmp/*
/tmp/*
# copy files
COPY root/ /

View File

@ -1,4 +1,4 @@
FROM ghcr.io/linuxserver/baseimage-ubuntu:arm64v8-focal
FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.15
# set version label
ARG BUILD_DATE
@ -14,22 +14,19 @@ ARG DEBIAN_FRONTEND="noninteractive"
ENV HOME /config
RUN \
echo "**** add mono repository ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
echo "deb https://download.mono-project.com/repo/ubuntu focal main" | tee /etc/apt/sources.list.d/mono-official.list && \
echo "**** install packages ****" && \
apt-get update && \
apt-get install -y \
cron \
libmono-system-data4.0-cil \
libmono-system-net-http-webrequest4.0-cil \
libmono-system-web4.0-cil \
mono-devel \
mono-runtime \
apk -U --update --no-cache add \
bash \
curl \
icu-libs \
iputils \
unzip && \
echo "**** install dotnet sdk ****" && \
mkdir -p /app/dotnet && \
curl -o /tmp/dotnet-install.sh -L \
https://dot.net/v1/dotnet-install.sh && \
chmod +x /tmp/dotnet-install.sh && \
/tmp/dotnet-install.sh -c 5.0 --install-dir /app/dotnet --runtime dotnet && \
echo "**** install webgrabplus ****" && \
if [ -z "$WEBGRAB_VER" ]; then \
WEBGRAB_VER=$(curl -fsL http://webgrabplus.com/download/sw | grep -m1 /download/sw/v | sed 's|.*/download/sw/v\(.*\)">V.*|\1|'); \

View File

@ -1,4 +1,10 @@
FROM ghcr.io/linuxserver/baseimage-ubuntu:arm32v7-focal
FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.15
# set version label
ARG BUILD_DATE
ARG VERSION
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
LABEL maintainer="saarg"
# package versions
ARG WEBGRAB_VER
@ -8,22 +14,19 @@ ARG DEBIAN_FRONTEND="noninteractive"
ENV HOME /config
RUN \
echo "**** add mono repository ****" && \
apt-get update && \
apt-get install -y \
gnupg && \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \
echo "deb https://download.mono-project.com/repo/ubuntu focal main" | tee /etc/apt/sources.list.d/mono-official.list && \
echo "**** install packages ****" && \
apt-get update && \
apt-get install -y \
cron \
libmono-system-data4.0-cil \
libmono-system-net-http-webrequest4.0-cil \
libmono-system-web4.0-cil \
mono-devel \
mono-runtime \
apk -U --update --no-cache add \
bash \
curl \
icu-libs \
iputils \
unzip && \
echo "**** install dotnet sdk ****" && \
mkdir -p /app/dotnet && \
curl -o /tmp/dotnet-install.sh -L \
https://dot.net/v1/dotnet-install.sh && \
chmod +x /tmp/dotnet-install.sh && \
/tmp/dotnet-install.sh -c 5.0 --install-dir /app/dotnet --runtime dotnet && \
echo "**** install webgrabplus ****" && \
if [ -z "$WEBGRAB_VER" ]; then \
WEBGRAB_VER=$(curl -fsL http://webgrabplus.com/download/sw | grep -m1 /download/sw/v | sed 's|.*/download/sw/v\(.*\)">V.*|\1|'); \

2
Jenkinsfile vendored
View File

@ -24,7 +24,7 @@ pipeline {
DOCKERHUB_IMAGE = 'linuxserver/webgrabplus'
DEV_DOCKERHUB_IMAGE = 'lsiodev/webgrabplus'
PR_DOCKERHUB_IMAGE = 'lspipepr/webgrabplus'
DIST_IMAGE = 'ubuntu'
DIST_IMAGE = 'alpine'
MULTIARCH='true'
CI='true'
CI_WEB='false'

View File

@ -246,6 +246,8 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
## Versions
* **23.03.22:** - Rebase to Alpine 3.15.
* **23.03.22:** - Update to use dotnet instead of mono.
* **06.01.22:** - Rebase to Ubuntu focal. Enable auto builds on version updates (beta and stable).
* **17.12.21:** - Update to version 3.2.2 beta.
* **05.08.21:** - Update to version 3.2.1 beta.

View File

@ -15,7 +15,7 @@ repo_vars:
- DOCKERHUB_IMAGE = 'linuxserver/webgrabplus'
- DEV_DOCKERHUB_IMAGE = 'lsiodev/webgrabplus'
- PR_DOCKERHUB_IMAGE = 'lspipepr/webgrabplus'
- DIST_IMAGE = 'ubuntu'
- DIST_IMAGE = 'alpine'
- MULTIARCH='true'
- CI='true'
- CI_WEB='false'

View File

@ -34,6 +34,8 @@ app_setup_block_enabled: true
app_setup_block: |
To configure WebGrab+Plus follow the [documentation](http://www.webgrabplus.com/documentation/configuration/)
**Please note that depending on your host this container may not work with the `no-new-privileges=true` security-opt.**
Note that there are some things in the guide that does not apply to this container. Below you can find the changes.
**The configuration files are found where your config volume is mounted.**
@ -62,6 +64,8 @@ app_setup_block: |
# changelog
changelogs:
- { date: "23.03.22:", desc: "Rebase to Alpine 3.15." }
- { date: "23.03.22:", desc: "Update to use dotnet instead of mono." }
- { date: "06.01.22:", desc: "Rebase to Ubuntu focal. Enable auto builds on version updates (beta and stable)." }
- { date: "17.12.21:", desc: "Update to version 3.2.2 beta." }
- { date: "05.08.21:", desc: "Update to version 3.2.1 beta." }

4
root/defaults/update.sh Normal file → Executable file
View File

@ -1,7 +1,7 @@
#!/bin/bash
cd /app/wg++/bin || exit
cd /app/wg++/bin.net || exit
mono WebGrab+Plus.exe "/config"
/app/dotnet/dotnet "WebGrab+Plus.dll" "/config"
exit 0

View File

@ -14,7 +14,12 @@ echo "******** Please use the file wg3-cron to adjust the scheduled time for run
cp /defaults/wg3-cron /config/wg3-cron
crontab -u abc /config/wg3-cron
mkdir -p /app/wg++/bin.net/WebGrab+Plus
mkdir -p /config/License
ln -sf /config/License /app/wg++/bin.net/WebGrab+Plus
# permissions
chown -R abc:abc \
/app \
/config \
/data

View File

@ -1,3 +1,3 @@
#!/usr/bin/with-contenv bash
exec /usr/sbin/cron -f -L 1
exec /usr/sbin/crond -f -L 1