Skip to content

Commit 33bcc82

Browse files
committed
Add dockerfile
1 parent 6f03bcd commit 33bcc82

File tree

3 files changed

+26
-4
lines changed

3 files changed

+26
-4
lines changed

Dockerfile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
ARG BASE=ghcr.io/void-linux/void-linux:20210312rc01-thin-x86_64-musl
2+
FROM ${BASE}
3+
RUN xbps-install -yMU git bash curl util-linux findutils
4+
COPY void-updates.sh /usr/local/bin/void-updates
5+
COPY entrypoint.sh /entrypoint
6+
7+
# Needed to allow the update checker to run as root.
8+
ENV XBPS_ALLOW_CHROOT_BREAKOUT=1
9+
ENV PARALLELISM=20
10+
11+
ENTRYPOINT ["/entrypoint"]

entrypoint.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/sh
2+
3+
if [ -d /void-packages-origin/.git ] ; then
4+
printf "local origin is possible, bootstrapping from that...\n"
5+
git clone /void-packages-origin /void-packages
6+
fi
7+
8+
/usr/local/bin/void-updates \
9+
-p "$PARALLELISM" \
10+
-r https://github.com/void-linux/void-packages.git \
11+
-s /void-packages \
12+
-o /void-updates

void-updates.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,12 @@ init_src() {
77
mkdir -p $src
88
git clone -q $repo $src
99
fi
10-
11-
if ! [ -d $src/hostdir/binpkgs ]; then
12-
(cd $src && ./xbps-src binary-bootstrap)
13-
fi
1410
}
1511

1612
update_src() {
13+
printf "updating clone\n"
1714
GIT_WORK_TREE=$src GIT_DIR=$src/.git git pull -q
15+
printf "update complete\n"
1816
}
1917

2018
is_meta() {
@@ -106,6 +104,7 @@ add_homepage() {
106104
}
107105

108106
parallel_check() {
107+
printf "beginning checks\n"
109108
xargs -P20 -L1 /bin/sh -c "
110109
(cd $src && ./xbps-src update-check \$0) |
111110
sed -e \"s|\$0-||g\" -e \"s|^|\$0 |\" >> \$1

0 commit comments

Comments
 (0)