Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 2.4.0.M5 and update scripts for easier version management #200

Merged
merged 1 commit into from Nov 7, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
116 changes: 64 additions & 52 deletions .travis.yml
@@ -1,3 +1,10 @@
#
# ------------------------------------------------------------------------------
# NOTE: THIS TRAVIS CONFIGURATION IS GENERATED VIA "update.sh"
#
# PLEASE DO NOT EDIT IT DIRECTLY.
# ------------------------------------------------------------------------------
#
sudo: required
language: bash
branches:
Expand All @@ -6,7 +13,7 @@ branches:
services:
- docker
before_install:
- ./update.sh
- ./update-docker-files.sh
- docker info
- docker run --rm --privileged multiarch/qemu-user-static:register --reset
install:
Expand All @@ -15,61 +22,66 @@ install:
after_success:
- docker login -u=$DOCKER_USERNAME -p=$DOCKER_PASSWORD
- docker push $DOCKER_REPO:$VERSION-$TARGET-$DIST
matrix:
fast_finish: true
env:
#global:
# - DOCKER_REPO=openhab/openhab
# Encrypted:
# - DOCKER_EMAIL
# - DOCKER_USERNAME
# - DOCKER_PASSWORD
matrix:
- DIST=debian TARGET=amd64 VERSION=1.8.3
- DIST=debian TARGET=armhf VERSION=1.8.3
- DIST=debian TARGET=arm64 VERSION=1.8.3
- DIST=debian TARGET=amd64 VERSION=2.0.0
- DIST=debian TARGET=armhf VERSION=2.0.0
- DIST=debian TARGET=arm64 VERSION=2.0.0
- DIST=debian TARGET=amd64 VERSION=2.1.0
- DIST=debian TARGET=armhf VERSION=2.1.0
- DIST=debian TARGET=arm64 VERSION=2.1.0
- DIST=debian TARGET=amd64 VERSION=2.2.0
- DIST=debian TARGET=armhf VERSION=2.2.0
- DIST=debian TARGET=arm64 VERSION=2.2.0
- DIST=debian TARGET=amd64 VERSION=2.3.0
- DIST=debian TARGET=armhf VERSION=2.3.0
- DIST=debian TARGET=arm64 VERSION=2.3.0
- DIST=debian TARGET=amd64 VERSION=2.4.0-snapshot
- DIST=debian TARGET=armhf VERSION=2.4.0-snapshot
- DIST=debian TARGET=arm64 VERSION=2.4.0-snapshot
- DIST=debian TARGET=amd64 VERSION=2.4.0.M3
- DIST=debian TARGET=armhf VERSION=2.4.0.M3
- DIST=debian TARGET=arm64 VERSION=2.4.0.M3
- DIST=debian TARGET=amd64 VERSION=2.4.0.M4
- DIST=debian TARGET=armhf VERSION=2.4.0.M4
- DIST=debian TARGET=arm64 VERSION=2.4.0.M4
- DIST=alpine TARGET=amd64 VERSION=1.8.3
- DIST=alpine TARGET=armhf VERSION=1.8.3
- DIST=alpine TARGET=arm64 VERSION=1.8.3
- DIST=alpine TARGET=amd64 VERSION=2.0.0
- DIST=alpine TARGET=armhf VERSION=2.0.0
- DIST=alpine TARGET=arm64 VERSION=2.0.0
- DIST=alpine TARGET=amd64 VERSION=2.1.0
- DIST=alpine TARGET=armhf VERSION=2.1.0
- DIST=alpine TARGET=arm64 VERSION=2.1.0
- DIST=alpine TARGET=amd64 VERSION=2.2.0
- DIST=alpine TARGET=armhf VERSION=2.2.0
- DIST=alpine TARGET=arm64 VERSION=2.2.0
- DIST=alpine TARGET=amd64 VERSION=2.3.0
- DIST=alpine TARGET=armhf VERSION=2.3.0
- DIST=alpine TARGET=arm64 VERSION=2.3.0
- DIST=alpine TARGET=amd64 VERSION=2.4.0-snapshot
- DIST=alpine TARGET=armhf VERSION=2.4.0-snapshot
- DIST=alpine TARGET=arm64 VERSION=2.4.0-snapshot
- DIST=alpine TARGET=amd64 VERSION=2.4.0.M3
- DIST=alpine TARGET=armhf VERSION=2.4.0.M3
- DIST=alpine TARGET=arm64 VERSION=2.4.0.M3
- DIST=alpine TARGET=amd64 VERSION=2.4.0.M4
- DIST=alpine TARGET=armhf VERSION=2.4.0.M4
- DIST=alpine TARGET=arm64 VERSION=2.4.0.M4
matrix:
fast_finish: true
- VERSION=1.8.3 DIST=alpine TARGET=amd64
- VERSION=1.8.3 DIST=alpine TARGET=arm64
- VERSION=1.8.3 DIST=alpine TARGET=armhf
- VERSION=1.8.3 DIST=debian TARGET=amd64
- VERSION=1.8.3 DIST=debian TARGET=arm64
- VERSION=1.8.3 DIST=debian TARGET=armhf
- VERSION=2.0.0 DIST=alpine TARGET=amd64
- VERSION=2.0.0 DIST=alpine TARGET=arm64
- VERSION=2.0.0 DIST=alpine TARGET=armhf
- VERSION=2.0.0 DIST=debian TARGET=amd64
- VERSION=2.0.0 DIST=debian TARGET=arm64
- VERSION=2.0.0 DIST=debian TARGET=armhf
- VERSION=2.1.0 DIST=alpine TARGET=amd64
- VERSION=2.1.0 DIST=alpine TARGET=arm64
- VERSION=2.1.0 DIST=alpine TARGET=armhf
- VERSION=2.1.0 DIST=debian TARGET=amd64
- VERSION=2.1.0 DIST=debian TARGET=arm64
- VERSION=2.1.0 DIST=debian TARGET=armhf
- VERSION=2.2.0 DIST=alpine TARGET=amd64
- VERSION=2.2.0 DIST=alpine TARGET=arm64
- VERSION=2.2.0 DIST=alpine TARGET=armhf
- VERSION=2.2.0 DIST=debian TARGET=amd64
- VERSION=2.2.0 DIST=debian TARGET=arm64
- VERSION=2.2.0 DIST=debian TARGET=armhf
- VERSION=2.3.0 DIST=alpine TARGET=amd64
- VERSION=2.3.0 DIST=alpine TARGET=arm64
- VERSION=2.3.0 DIST=alpine TARGET=armhf
- VERSION=2.3.0 DIST=debian TARGET=amd64
- VERSION=2.3.0 DIST=debian TARGET=arm64
- VERSION=2.3.0 DIST=debian TARGET=armhf
- VERSION=2.4.0.M3 DIST=alpine TARGET=amd64
- VERSION=2.4.0.M3 DIST=alpine TARGET=arm64
- VERSION=2.4.0.M3 DIST=alpine TARGET=armhf
- VERSION=2.4.0.M3 DIST=debian TARGET=amd64
- VERSION=2.4.0.M3 DIST=debian TARGET=arm64
- VERSION=2.4.0.M3 DIST=debian TARGET=armhf
- VERSION=2.4.0.M4 DIST=alpine TARGET=amd64
- VERSION=2.4.0.M4 DIST=alpine TARGET=arm64
- VERSION=2.4.0.M4 DIST=alpine TARGET=armhf
- VERSION=2.4.0.M4 DIST=debian TARGET=amd64
- VERSION=2.4.0.M4 DIST=debian TARGET=arm64
- VERSION=2.4.0.M4 DIST=debian TARGET=armhf
- VERSION=2.4.0.M5 DIST=alpine TARGET=amd64
- VERSION=2.4.0.M5 DIST=alpine TARGET=arm64
- VERSION=2.4.0.M5 DIST=alpine TARGET=armhf
- VERSION=2.4.0.M5 DIST=debian TARGET=amd64
- VERSION=2.4.0.M5 DIST=debian TARGET=arm64
- VERSION=2.4.0.M5 DIST=debian TARGET=armhf
- VERSION=2.4.0-snapshot DIST=alpine TARGET=amd64
- VERSION=2.4.0-snapshot DIST=alpine TARGET=arm64
- VERSION=2.4.0-snapshot DIST=alpine TARGET=armhf
- VERSION=2.4.0-snapshot DIST=debian TARGET=amd64
- VERSION=2.4.0-snapshot DIST=debian TARGET=arm64
- VERSION=2.4.0-snapshot DIST=debian TARGET=armhf
2 changes: 1 addition & 1 deletion 1.8.3/amd64/alpine/Dockerfile
Expand Up @@ -67,7 +67,7 @@ ENV JAVA_HOME='/usr/lib/jvm/java-1.8-openjdk'
RUN rm -r "$JAVA_HOME/jre/lib/security/policy/unlimited" && \
sed -i 's/^crypto.policy=unlimited/crypto.policy=limited/' "$JAVA_HOME/jre/lib/security/java.security"

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand Down
10 changes: 5 additions & 5 deletions 1.8.3/amd64/alpine/entrypoint.sh
Expand Up @@ -27,17 +27,17 @@ fi

# Copy initial files to host volume
case ${OPENHAB_VERSION} in
1.8.3)
1.*)
if [ -z "$(ls -A "${APPDIR}/configurations")" ]; then
# Copy userdata dir for version 1.8.3
# Copy userdata dir for openHAB 1.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/configurations.dist/." "${APPDIR}/configurations/"
fi
;;
2.0.0|2.1.0|2.2.0|2.3.0|2.4.*)
2.*)
# Initialize empty host volumes
if [ -z "$(ls -A "${APPDIR}/userdata")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No userdata found... initializing."
cp -av "${APPDIR}/userdata.dist/." "${APPDIR}/userdata/"
fi
Expand Down Expand Up @@ -91,7 +91,7 @@ case ${OPENHAB_VERSION} in
fi

if [ -z "$(ls -A "${APPDIR}/conf")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/conf.dist/." "${APPDIR}/conf/"
fi
Expand Down
3 changes: 2 additions & 1 deletion 1.8.3/amd64/debian/Dockerfile
Expand Up @@ -72,7 +72,7 @@ RUN wget -nv -O /tmp/java.tar.gz "${JAVA_URL}" && \
update-alternatives --install /usr/bin/java java "${JAVA_HOME}/bin/java" 50 && \
update-alternatives --install /usr/bin/javac javac "${JAVA_HOME}/bin/javac" 50

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand All @@ -85,6 +85,7 @@ VOLUME ${APPDIR}/configurations ${APPDIR}/addons
# Reduce image size by removing files that are used only for building the image
RUN DEBIAN_FRONTEND=noninteractive apt-get remove -y dirmngr gnupg && \
DEBIAN_FRONTEND=noninteractive apt-get autoremove -y && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

# Expose HTTP and HTTPS ports
Expand Down
12 changes: 6 additions & 6 deletions 1.8.3/amd64/debian/entrypoint.sh
Expand Up @@ -16,7 +16,7 @@ fi
# See: https://github.com/openhab/openhab-docker/issues/99
rm -f /openhab/runtime/instances/instance.properties

# The instance.properties file in OH2.x is installed in the tmp
# The instance.properties file in openHAB 2.x is installed in the tmp
# directory
rm -f /openhab/userdata/tmp/instances/instance.properties

Expand Down Expand Up @@ -47,17 +47,17 @@ fi

# Copy initial files to host volume
case ${OPENHAB_VERSION} in
1.8.3)
1.*)
if [ -z "$(ls -A "${APPDIR}/configurations")" ]; then
# Copy userdata dir for version 1.8.3
# Copy userdata dir for openHAB 1.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/configurations.dist/." "${APPDIR}/configurations/"
fi
;;
2.0.0|2.1.0|2.2.0|2.3.0|2.4.*)
2.*)
# Initialize empty host volumes
if [ -z "$(ls -A "${APPDIR}/userdata")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No userdata found... initializing."
cp -av "${APPDIR}/userdata.dist/." "${APPDIR}/userdata/"
fi
Expand Down Expand Up @@ -111,7 +111,7 @@ case ${OPENHAB_VERSION} in
fi

if [ -z "$(ls -A "${APPDIR}/conf")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/conf.dist/." "${APPDIR}/conf/"
fi
Expand Down
2 changes: 1 addition & 1 deletion 1.8.3/arm64/alpine/Dockerfile
Expand Up @@ -67,7 +67,7 @@ ENV JAVA_HOME='/usr/lib/jvm/java-1.8-openjdk'
RUN rm -r "$JAVA_HOME/jre/lib/security/policy/unlimited" && \
sed -i 's/^crypto.policy=unlimited/crypto.policy=limited/' "$JAVA_HOME/jre/lib/security/java.security"

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand Down
10 changes: 5 additions & 5 deletions 1.8.3/arm64/alpine/entrypoint.sh
Expand Up @@ -27,17 +27,17 @@ fi

# Copy initial files to host volume
case ${OPENHAB_VERSION} in
1.8.3)
1.*)
if [ -z "$(ls -A "${APPDIR}/configurations")" ]; then
# Copy userdata dir for version 1.8.3
# Copy userdata dir for openHAB 1.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/configurations.dist/." "${APPDIR}/configurations/"
fi
;;
2.0.0|2.1.0|2.2.0|2.3.0|2.4.*)
2.*)
# Initialize empty host volumes
if [ -z "$(ls -A "${APPDIR}/userdata")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No userdata found... initializing."
cp -av "${APPDIR}/userdata.dist/." "${APPDIR}/userdata/"
fi
Expand Down Expand Up @@ -91,7 +91,7 @@ case ${OPENHAB_VERSION} in
fi

if [ -z "$(ls -A "${APPDIR}/conf")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/conf.dist/." "${APPDIR}/conf/"
fi
Expand Down
3 changes: 2 additions & 1 deletion 1.8.3/arm64/debian/Dockerfile
Expand Up @@ -77,7 +77,7 @@ RUN dpkg --add-architecture armhf && \
apt-get install --no-install-recommends -y \
libc6:armhf

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand All @@ -90,6 +90,7 @@ VOLUME ${APPDIR}/configurations ${APPDIR}/addons
# Reduce image size by removing files that are used only for building the image
RUN DEBIAN_FRONTEND=noninteractive apt-get remove -y dirmngr gnupg && \
DEBIAN_FRONTEND=noninteractive apt-get autoremove -y && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

# Expose HTTP and HTTPS ports
Expand Down
12 changes: 6 additions & 6 deletions 1.8.3/arm64/debian/entrypoint.sh
Expand Up @@ -16,7 +16,7 @@ fi
# See: https://github.com/openhab/openhab-docker/issues/99
rm -f /openhab/runtime/instances/instance.properties

# The instance.properties file in OH2.x is installed in the tmp
# The instance.properties file in openHAB 2.x is installed in the tmp
# directory
rm -f /openhab/userdata/tmp/instances/instance.properties

Expand Down Expand Up @@ -47,17 +47,17 @@ fi

# Copy initial files to host volume
case ${OPENHAB_VERSION} in
1.8.3)
1.*)
if [ -z "$(ls -A "${APPDIR}/configurations")" ]; then
# Copy userdata dir for version 1.8.3
# Copy userdata dir for openHAB 1.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/configurations.dist/." "${APPDIR}/configurations/"
fi
;;
2.0.0|2.1.0|2.2.0|2.3.0|2.4.*)
2.*)
# Initialize empty host volumes
if [ -z "$(ls -A "${APPDIR}/userdata")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No userdata found... initializing."
cp -av "${APPDIR}/userdata.dist/." "${APPDIR}/userdata/"
fi
Expand Down Expand Up @@ -111,7 +111,7 @@ case ${OPENHAB_VERSION} in
fi

if [ -z "$(ls -A "${APPDIR}/conf")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/conf.dist/." "${APPDIR}/conf/"
fi
Expand Down
2 changes: 1 addition & 1 deletion 1.8.3/armhf/alpine/Dockerfile
Expand Up @@ -67,7 +67,7 @@ ENV JAVA_HOME='/usr/lib/jvm/java-1.8-openjdk'
RUN rm -r "$JAVA_HOME/jre/lib/security/policy/unlimited" && \
sed -i 's/^crypto.policy=unlimited/crypto.policy=limited/' "$JAVA_HOME/jre/lib/security/java.security"

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand Down
10 changes: 5 additions & 5 deletions 1.8.3/armhf/alpine/entrypoint.sh
Expand Up @@ -27,17 +27,17 @@ fi

# Copy initial files to host volume
case ${OPENHAB_VERSION} in
1.8.3)
1.*)
if [ -z "$(ls -A "${APPDIR}/configurations")" ]; then
# Copy userdata dir for version 1.8.3
# Copy userdata dir for openHAB 1.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/configurations.dist/." "${APPDIR}/configurations/"
fi
;;
2.0.0|2.1.0|2.2.0|2.3.0|2.4.*)
2.*)
# Initialize empty host volumes
if [ -z "$(ls -A "${APPDIR}/userdata")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No userdata found... initializing."
cp -av "${APPDIR}/userdata.dist/." "${APPDIR}/userdata/"
fi
Expand Down Expand Up @@ -91,7 +91,7 @@ case ${OPENHAB_VERSION} in
fi

if [ -z "$(ls -A "${APPDIR}/conf")" ]; then
# Copy userdata dir for version 2.0.0
# Copy userdata dir for openHAB 2.x
echo "No configuration found... initializing."
cp -av "${APPDIR}/conf.dist/." "${APPDIR}/conf/"
fi
Expand Down
3 changes: 2 additions & 1 deletion 1.8.3/armhf/debian/Dockerfile
Expand Up @@ -72,7 +72,7 @@ RUN wget -nv -O /tmp/java.tar.gz "${JAVA_URL}" && \
update-alternatives --install /usr/bin/java java "${JAVA_HOME}/bin/java" 50 && \
update-alternatives --install /usr/bin/javac javac "${JAVA_HOME}/bin/javac" 50

# Install openhab
# Install openHAB
RUN wget -nv -O /tmp/openhab.zip "${OPENHAB_URL}" && \
unzip -q /tmp/openhab.zip -d "${APPDIR}" && \
rm /tmp/openhab.zip && \
Expand All @@ -85,6 +85,7 @@ VOLUME ${APPDIR}/configurations ${APPDIR}/addons
# Reduce image size by removing files that are used only for building the image
RUN DEBIAN_FRONTEND=noninteractive apt-get remove -y dirmngr gnupg && \
DEBIAN_FRONTEND=noninteractive apt-get autoremove -y && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

# Expose HTTP and HTTPS ports
Expand Down