Merge branch 'master' into k8s

* master:
  Official tag time
  Docker Pi-hole v4.3
This commit is contained in:
Martin Buchleitner 2019-05-28 09:15:08 +02:00
commit 09131ad78f
9 changed files with 26 additions and 23 deletions

View File

@ -38,7 +38,8 @@ os_base_vars = {
__version__ = None
dot = os.path.abspath('.')
with open('{}/VERSION'.format(dot), 'r') as v:
__version__ = v.read().strip()
raw_version = v.read().strip()
__version__ = raw_version.replace('release/', 'release-')
images = {
__version__: [

View File

@ -36,11 +36,11 @@ ENV ServerIP 0.0.0.0
ENV FTL_CMD no-daemon
ENV DNSMASQ_USER root
ENV VERSION v4.2.2
ENV VERSION v4.3
ENV ARCH aarch64
ENV PATH /opt/pihole:${PATH}
LABEL image="pihole/pihole:v4.2.2_aarch64"
LABEL image="pihole/pihole:v4.3_aarch64"
LABEL maintainer="adam@diginc.us"
LABEL url="https://www.github.com/pi-hole/docker-pi-hole"

View File

@ -36,11 +36,11 @@ ENV ServerIP 0.0.0.0
ENV FTL_CMD no-daemon
ENV DNSMASQ_USER root
ENV VERSION v4.2.2
ENV VERSION v4.3
ENV ARCH amd64
ENV PATH /opt/pihole:${PATH}
LABEL image="pihole/pihole:v4.2.2_amd64"
LABEL image="pihole/pihole:v4.3_amd64"
LABEL maintainer="adam@diginc.us"
LABEL url="https://www.github.com/pi-hole/docker-pi-hole"

View File

@ -36,11 +36,11 @@ ENV ServerIP 0.0.0.0
ENV FTL_CMD no-daemon
ENV DNSMASQ_USER root
ENV VERSION v4.2.2
ENV VERSION v4.3
ENV ARCH armel
ENV PATH /opt/pihole:${PATH}
LABEL image="pihole/pihole:v4.2.2_armel"
LABEL image="pihole/pihole:v4.3_armel"
LABEL maintainer="adam@diginc.us"
LABEL url="https://www.github.com/pi-hole/docker-pi-hole"

View File

@ -36,11 +36,11 @@ ENV ServerIP 0.0.0.0
ENV FTL_CMD no-daemon
ENV DNSMASQ_USER root
ENV VERSION v4.2.2
ENV VERSION v4.3
ENV ARCH armhf
ENV PATH /opt/pihole:${PATH}
LABEL image="pihole/pihole:v4.2.2_armhf"
LABEL image="pihole/pihole:v4.3_armhf"
LABEL maintainer="adam@diginc.us"
LABEL url="https://www.github.com/pi-hole/docker-pi-hole"

View File

@ -1 +1 @@
v4.2.2
v4.3

View File

@ -1,5 +1,5 @@
#!/bin/bash -e
# Script for manually pushing the docker arm images for diginc only
# Script for manually pushing the docker arm images for pi-hole org members only
# (no one else has docker repo permissions)
if [ ! -f ~/.docker/config.json ] ; then
echo "Error: You should setup your docker push authorization first"
@ -7,7 +7,9 @@ if [ ! -f ~/.docker/config.json ] ; then
fi
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/'
var="$(git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/')"
# convert release/ to release-
echo "${var/release\//release-}"
}
annotate() {
@ -44,7 +46,7 @@ if [[ "$version" == 'unset' ]]; then
if [[ "$branch" == "master" ]]; then
echo "Version number var is unset and master branch needs a version...pass in \$version variable!"
exit 1
elif [[ "$branch" = "release/"* ]]; then
elif [[ "$branch" == "release-"* ]]; then
version="$(echo $branch | grep -Po 'v[\d\w\.-]*')"
echo "Version number is being taken from this release branch $version"
else

View File

@ -4,21 +4,20 @@ mkdir -p $CONFIG_DIR/
mkdir -p /var/run/pihole
# Production tags with valid web footers
export CORE_VERSION="$(cat /etc/docker-pi-hole-version)"
# Major.Minor for web tag until patches are released for it
export WEB_VERSION="$(echo ${CORE_VERSION} | grep -Po "v\d+\.\d+")"
export WEB_VERSION="${CORE_VERSION}"
# Only use for pre-production / testing
export USE_CUSTOM_BRANCHES=false
export CHECKOUT_BRANCHES=false
# Search for release/* branch naming convention for custom checkouts
if [[ "$CORE_VERSION" == *"release/"* ]] ; then
CHECKOUT_BRANCHES=true
fi
apt-get update
apt-get install -y curl procps
curl -L -s $S6OVERLAY_RELEASE | tar xvzf - -C /
mv /init /s6-init
if [[ $USE_CUSTOM_BRANCHES == true ]] ; then
CORE_VERSION="hotfix/${CORE_VERSION}"
WEB_VERSION="release/v4.2"
fi
# debconf-apt-progress seems to hang so get rid of it too
which debconf-apt-progress
mv "$(which debconf-apt-progress)" /bin/no_debconf-apt-progress
@ -68,7 +67,7 @@ FTLdetect 2>&1 | tee "${tmpLog}"
installPihole 2>&1 | tee "${tmpLog}"
mv "${tmpLog}" /
if [[ $USE_CUSTOM_BRANCHES == true ]] ; then
if [[ $CHECKOUT_BRANCHES == true ]] ; then
ln -s /bin/true /usr/local/bin/service
ln -s /bin/true /usr/local/bin/update-rc.d
echo y | bash -x pihole checkout core ${CORE_VERSION}

View File

@ -9,7 +9,8 @@ check_output = testinfra.get_backend(
__version__ = None
dotdot = os.path.abspath(os.path.join(os.path.abspath(__file__), os.pardir, os.pardir))
with open('{}/VERSION'.format(dotdot), 'r') as v:
__version__ = v.read().strip()
raw_version = v.read().strip()
__version__ = raw_version.replace('release/', 'release-')
@pytest.fixture()
def args_dns():