Skip to content

Commit 62d9998

Browse files
authored
Merge pull request #6 from linuxserver/version-change
ingest version from new source, do not use at buildtime
2 parents f98246a + 137e23c commit 62d9998

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

Dockerfile

+5-8
Original file line numberDiff line numberDiff line change
@@ -11,25 +11,22 @@ LABEL maintainer="aptalca"
1111
ENV NVIDIA_DRIVER_CAPABILITIES="compute,video,utility"
1212

1313
# global environment settings
14-
ENV DEBIAN_FRONTEND="noninteractive"
14+
ENV DEBIAN_FRONTEND="noninteractive" \
15+
MAJOR_VERSION=7.6
1516

1617
RUN \
1718
echo "**** install runtime packages ****" && \
1819
apt-get update && \
1920
apt-get install -y \
2021
libnvidia-compute-435 \
22+
jq \
2123
ocl-icd-libopencl1 && \
2224
ln -s libOpenCL.so.1 /usr/lib/x86_64-linux-gnu/libOpenCL.so && \
2325
echo "**** install foldingathome ****" && \
24-
if [ -z ${FOLDINGATHOME_RELEASE+x} ]; then \
25-
FOLDINGATHOME_RELEASE="$(curl -sL https://download.foldingathome.org/js/fah-downloads.js \
26-
| awk -F'(fahclient_|_amd64.deb)' '/debian-stable-64bit/ {print $2;exit}')"; \
27-
fi && \
28-
MAJOR_VERSION="$(curl -sL https://download.foldingathome.org/js/fah-downloads.js \
29-
| awk -F'(/debian-stable-64bit/|/fahclient_)' '/debian-stable-64bit/ {print $2;exit}')" && \
26+
download_url=$(curl -sL https://download.foldingathome.org/releases.py?series=${MAJOR_VERSION} | jq -r '.[] | select(.title=="64bit Linux") | .groups[0].files[0].url') && \
3027
curl -o \
3128
/tmp/fah.deb -L \
32-
"https://download.foldingathome.org/releases/public/release/fahclient/debian-stable-64bit/${MAJOR_VERSION}/fahclient_${FOLDINGATHOME_RELEASE}_amd64.deb" && \
29+
${download_url} && \
3330
dpkg -x /tmp/fah.deb /app && \
3431
echo "**** cleanup ****" && \
3532
apt-get clean && \

Jenkinsfile

+2-1
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ pipeline {
103103
steps{
104104
script{
105105
env.EXT_RELEASE = sh(
106-
script: ''' curl -sL https://download.foldingathome.org/js/fah-downloads.js | awk -F'(fahclient_|_amd64.deb)' '/debian-stable-64bit/ {print $2;exit}' ''',
106+
script: ''' curl -sL https://download.foldingathome.org/releases.py?series=7.6 | jq -r '.[] | select(.title=="64bit Linux") | .groups[0].files[0].filename' | awk -F'(fahclient_|_amd64.deb)' '{print $2}'
107+
''',
107108
returnStdout: true).trim()
108109
env.RELEASE_LINK = 'custom_command'
109110
}

jenkins-vars.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
# jenkins variables
44
project_name: docker-foldingathome
55
external_type: na
6-
custom_version_command: "curl -sL https://download.foldingathome.org/js/fah-downloads.js | awk -F'(fahclient_|_amd64.deb)' '/debian-stable-64bit/ {print $2;exit}'"
6+
custom_version_command: |
7+
curl -sL https://download.foldingathome.org/releases.py?series=7.6 | jq -r '.[] | select(.title=="64bit Linux") | .groups[0].files[0].filename' | awk -F'(fahclient_|_amd64.deb)' '{print $2}'
78
release_type: stable
89
release_tag: latest
910
ls_branch: master

0 commit comments

Comments
 (0)