mirror of
https://github.com/linuxserver/docker-cops.git
synced 2026-04-06 00:00:04 +08:00
commit
91d4ddb69b
30
Dockerfile
30
Dockerfile
@ -6,11 +6,13 @@ ARG BUILD_DATE
|
||||
ARG VERSION
|
||||
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
|
||||
|
||||
# set package version
|
||||
ENV COPS_VER="1.1.0"
|
||||
# install build packages
|
||||
RUN \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
curl \
|
||||
tar && \
|
||||
|
||||
# install runtime packages
|
||||
RUN \
|
||||
apk add --no-cache \
|
||||
--repository http://nl.alpinelinux.org/alpine/edge/main \
|
||||
icu-libs \
|
||||
@ -23,14 +25,22 @@ RUN \
|
||||
php7-mbstring \
|
||||
php7-opcache \
|
||||
php7-openssl \
|
||||
php7-phar \
|
||||
php7-pdo_sqlite \
|
||||
php7-zlib
|
||||
php7-zip \
|
||||
php7-zlib && \
|
||||
|
||||
# install composer
|
||||
ln -sf /usr/bin/php7 /usr/bin/php && \
|
||||
curl \
|
||||
-sS https://getcomposer.org/installer \
|
||||
| php -- --install-dir=/usr/bin --filename=composer && \
|
||||
composer \
|
||||
global require "fxp/composer-asset-plugin:~1.1" && \
|
||||
|
||||
# install cops
|
||||
RUN \
|
||||
apk add --no-cache --virtual=build-dependencies \
|
||||
curl \
|
||||
tar && \
|
||||
COPS_VER=$(curl -sX GET "https://api.github.com/repos/seblucas/cops/releases/latest" \
|
||||
| awk '/tag_name/{print $4;exit}' FS='[""]') && \
|
||||
curl -o \
|
||||
/tmp/cops.tar.gz -L \
|
||||
"https://github.com/seblucas/cops/archive/${COPS_VER}.tar.gz" && \
|
||||
@ -38,11 +48,15 @@ RUN \
|
||||
/usr/share/webapps/cops && \
|
||||
tar xf /tmp/cops.tar.gz -C \
|
||||
/usr/share/webapps/cops --strip-components=1 && \
|
||||
cd /usr/share/webapps/cops && \
|
||||
composer \
|
||||
install --no-dev --optimize-autoloader && \
|
||||
|
||||
# cleanup
|
||||
apk del --purge \
|
||||
build-dependencies && \
|
||||
rm -rf \
|
||||
/root/.composer \
|
||||
/tmp/*
|
||||
|
||||
# add local files
|
||||
|
||||
@ -110,6 +110,7 @@ Unlike other implementations of COPS in a docker container, the linuxserver ver
|
||||
|
||||
## Versions
|
||||
|
||||
+ **03.04.17:** Add composer packages, reduce layers.
|
||||
+ **02.04.17:** Updated to version 1.1.0.
|
||||
+ **05.02.17:** Updated to Alpine 3.5 & PHP7.
|
||||
+ **24.10.16:** Updated to implement user based config.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user