File tree 3 files changed +27
-17
lines changed
3 files changed +27
-17
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ COPY qemu-aarch64-static /usr/bin
7
7
# set version label
8
8
ARG BUILD_DATE
9
9
ARG VERSION
10
+ ARG BOOKSTACK_RELEASE
10
11
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
11
12
LABEL maintainer="homerr"
12
13
@@ -36,14 +37,17 @@ echo "**** configure php-fpm to pass env vars ****" && \
36
37
37
38
echo "**** get bookstack ****" && \
38
39
39
- BSAPP_VER="$(curl -sX GET https://api.github.com/repos/BookStackApp/BookStack/releases/latest | grep 'tag_name' | cut -d\" -f4)" && \
40
-
41
40
mkdir -p\
42
41
/var/www/html && \
43
42
43
+ if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
44
+ BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
45
+ | awk '/tag_name/{print $4;exit}' FS='[""]'); \
46
+ fi && \
47
+
44
48
curl -o \
45
- /tmp/bookstack.tar.gz -L \
46
- "https://github.com/BookStackApp/BookStack/archive/${BSAPP_VER }.tar.gz" && \
49
+ /tmp/bookstack.tar.gz -L \
50
+ "https://github.com/BookStackApp/BookStack/archive/${BOOKSTACK_RELEASE }.tar.gz" && \
47
51
48
52
tar xf \
49
53
/tmp/bookstack.tar.gz -C \
@@ -57,7 +61,7 @@ cd /tmp && \
57
61
curl -sS https://getcomposer.org/installer | php && \
58
62
mv /tmp/composer.phar /usr/local/bin/composer && \
59
63
60
- echo "**** run composer install ****"
64
+ echo "**** run composer install ****" && \
61
65
62
66
composer install -d /var/www/html/ && \
63
67
Original file line number Diff line number Diff line change 1
- # using ideas/code from other sparklyballs templates
2
- # set variable to get archive based on github api data (sparklyballs heimdall inspiration)
3
-
1
+ # using ideas/code from other thelamer & sparklyballs lsio templates
4
2
FROM lsiobase/alpine.nginx:3.7
5
3
6
4
# set version label
7
5
ARG BUILD_DATE
8
6
ARG VERSION
7
+ ARG BOOKSTACK_RELEASE
9
8
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
10
9
LABEL maintainer="homerr"
11
10
@@ -35,14 +34,17 @@ echo "**** configure php-fpm to pass env vars ****" && \
35
34
36
35
echo "**** get bookstack ****" && \
37
36
38
- BSAPP_VER="$(curl -sX GET https://api.github.com/repos/BookStackApp/BookStack/releases/latest | grep 'tag_name' | cut -d\" -f4)" && \
39
-
40
37
mkdir -p\
41
38
/var/www/html && \
42
39
40
+ if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
41
+ BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
42
+ | awk '/tag_name/{print $4;exit}' FS='[""]'); \
43
+ fi && \
44
+
43
45
curl -o \
44
46
/tmp/bookstack.tar.gz -L \
45
- "https://github.com/BookStackApp/BookStack/archive/${BSAPP_VER }.tar.gz" && \
47
+ "https://github.com/BookStackApp/BookStack/archive/${BOOKSTACK_RELEASE }.tar.gz" && \
46
48
47
49
tar xf \
48
50
/tmp/bookstack.tar.gz -C \
@@ -56,7 +58,7 @@ cd /tmp && \
56
58
curl -sS https://getcomposer.org/installer | php && \
57
59
mv /tmp/composer.phar /usr/local/bin/composer && \
58
60
59
- echo "**** run composer install ****"
61
+ echo "**** run composer install ****" && \
60
62
61
63
composer install -d /var/www/html/ && \
62
64
Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ COPY qemu-arm-static /usr/bin
7
7
# set version label
8
8
ARG BUILD_DATE
9
9
ARG VERSION
10
+ ARG BOOKSTACK_RELEASE
10
11
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
11
12
LABEL maintainer="homerr"
12
13
@@ -36,14 +37,17 @@ echo "**** configure php-fpm to pass env vars ****" && \
36
37
37
38
echo "**** get bookstack ****" && \
38
39
39
- BSAPP_VER="$(curl -sX GET https://api.github.com/repos/BookStackApp/BookStack/releases/latest | grep 'tag_name' | cut -d\" -f4)" && \
40
-
41
40
mkdir -p\
42
41
/var/www/html && \
43
42
43
+ if [ -z ${BOOKSTACK_RELEASE+x} ]; then \
44
+ BOOKSTACK_RELEASE=$(curl -sX GET "https://api.github.com/repos/bookstackapp/bookstack/releases/latest" \
45
+ | awk '/tag_name/{print $4;exit}' FS='[""]'); \
46
+ fi && \
47
+
44
48
curl -o \
45
- /tmp/bookstack.tar.gz -L \
46
- "https://github.com/BookStackApp/BookStack/archive/${BSAPP_VER }.tar.gz" && \
49
+ /tmp/bookstack.tar.gz -L \
50
+ "https://github.com/BookStackApp/BookStack/archive/${BOOKSTACK_RELEASE }.tar.gz" && \
47
51
48
52
tar xf \
49
53
/tmp/bookstack.tar.gz -C \
@@ -57,7 +61,7 @@ cd /tmp && \
57
61
curl -sS https://getcomposer.org/installer | php && \
58
62
mv /tmp/composer.phar /usr/local/bin/composer && \
59
63
60
- echo "**** run composer install ****"
64
+ echo "**** run composer install ****" && \
61
65
62
66
composer install -d /var/www/html/ && \
63
67
You can’t perform that action at this time.
0 commit comments