From 1a2fff0c1a3d74c878a56f3f374113c11e4d19ef Mon Sep 17 00:00:00 2001 From: Kentaro Hayashi Date: Thu, 10 Jun 2021 10:24:48 +0900 Subject: [PATCH] Add Fluentd v1.13.0 images Closes: #269 Signed-off-by: Kentaro Hayashi --- .github/workflows/linux.yml | 4 +- Makefile | 14 ++--- README.md | 18 +++--- v1.13/alpine/Dockerfile | 55 +++++++++++++++++ v1.13/alpine/entrypoint.sh | 28 +++++++++ v1.13/alpine/fluent.conf | 33 ++++++++++ v1.13/alpine/hooks/post_push | 15 +++++ v1.13/arm64/debian/Dockerfile | 83 ++++++++++++++++++++++++++ v1.13/arm64/debian/entrypoint.sh | 28 +++++++++ v1.13/arm64/debian/fluent.conf | 33 ++++++++++ v1.13/arm64/debian/hooks/post_checkout | 19 ++++++ v1.13/arm64/debian/hooks/post_push | 15 +++++ v1.13/armhf/debian/Dockerfile | 83 ++++++++++++++++++++++++++ v1.13/armhf/debian/entrypoint.sh | 28 +++++++++ v1.13/armhf/debian/fluent.conf | 33 ++++++++++ v1.13/armhf/debian/hooks/post_checkout | 19 ++++++ v1.13/armhf/debian/hooks/post_push | 15 +++++ v1.13/debian/Dockerfile | 71 ++++++++++++++++++++++ v1.13/debian/entrypoint.sh | 28 +++++++++ v1.13/debian/fluent.conf | 33 ++++++++++ v1.13/debian/hooks/post_push | 15 +++++ v1.13/windows-2004/Dockerfile | 38 ++++++++++++ v1.13/windows-2004/entrypoint.sh | 28 +++++++++ v1.13/windows-2004/fluent.conf | 33 ++++++++++ v1.13/windows-2004/hooks/post_push | 15 +++++ v1.13/windows-20H2/Dockerfile | 38 ++++++++++++ v1.13/windows-20H2/entrypoint.sh | 28 +++++++++ v1.13/windows-20H2/fluent.conf | 33 ++++++++++ v1.13/windows-20H2/hooks/post_push | 15 +++++ v1.13/windows-ltsc2019/Dockerfile | 38 ++++++++++++ v1.13/windows-ltsc2019/entrypoint.sh | 28 +++++++++ v1.13/windows-ltsc2019/fluent.conf | 33 ++++++++++ v1.13/windows-ltsc2019/hooks/post_push | 15 +++++ 33 files changed, 994 insertions(+), 18 deletions(-) create mode 100644 v1.13/alpine/Dockerfile create mode 100755 v1.13/alpine/entrypoint.sh create mode 100644 v1.13/alpine/fluent.conf create mode 100755 v1.13/alpine/hooks/post_push create mode 100644 v1.13/arm64/debian/Dockerfile create mode 100755 v1.13/arm64/debian/entrypoint.sh create mode 100644 v1.13/arm64/debian/fluent.conf create mode 100644 v1.13/arm64/debian/hooks/post_checkout create mode 100755 v1.13/arm64/debian/hooks/post_push create mode 100644 v1.13/armhf/debian/Dockerfile create mode 100755 v1.13/armhf/debian/entrypoint.sh create mode 100644 v1.13/armhf/debian/fluent.conf create mode 100644 v1.13/armhf/debian/hooks/post_checkout create mode 100755 v1.13/armhf/debian/hooks/post_push create mode 100644 v1.13/debian/Dockerfile create mode 100755 v1.13/debian/entrypoint.sh create mode 100644 v1.13/debian/fluent.conf create mode 100755 v1.13/debian/hooks/post_push create mode 100644 v1.13/windows-2004/Dockerfile create mode 100755 v1.13/windows-2004/entrypoint.sh create mode 100644 v1.13/windows-2004/fluent.conf create mode 100755 v1.13/windows-2004/hooks/post_push create mode 100644 v1.13/windows-20H2/Dockerfile create mode 100755 v1.13/windows-20H2/entrypoint.sh create mode 100644 v1.13/windows-20H2/fluent.conf create mode 100755 v1.13/windows-20H2/hooks/post_push create mode 100644 v1.13/windows-ltsc2019/Dockerfile create mode 100755 v1.13/windows-ltsc2019/entrypoint.sh create mode 100644 v1.13/windows-ltsc2019/fluent.conf create mode 100755 v1.13/windows-ltsc2019/hooks/post_push diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index ef8afc16..50c7f9ca 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -9,8 +9,8 @@ jobs: fail-fast: false matrix: include: - - dockerfile: v1.12/alpine - - dockerfile: v1.12/debian + - dockerfile: v1.13/alpine + - dockerfile: v1.13/debian runs-on: ubuntu-latest steps: - uses: actions/checkout@master diff --git a/Makefile b/Makefile index 4418da7f..5778e045 100644 --- a/Makefile +++ b/Makefile @@ -13,22 +13,22 @@ IMAGE_NAME := fluent/fluentd X86_IMAGES := \ - v1.12/alpine:v1.12.4-1.2,v1.12-1,edge \ - v1.12/debian:v1.12.4-debian-1.2,v1.12-debian-1,edge-debian + v1.13/alpine:v1.13.0-1.0,v1.13-1,edge \ + v1.13/debian:v1.13.0-debian-1.0,v1.13-debian-1,edge-debian # :,,,... # Define images for running on ARM platforms ARM_IMAGES := \ - v1.12/armhf/debian:v1.12.4-debian-armhf-1.2,v1.12-debian-armhf-2,edge-debian-armhf \ + v1.13/armhf/debian:v1.13.0-debian-armhf-1.0,v1.13-debian-armhf-1,edge-debian-armhf \ # Define images for running on ARM64 platforms ARM64_IMAGES := \ - v1.12/arm64/debian:v1.12.4-debian-arm64-1.2,v1.12-debian-arm64-2,edge-debian-arm64 \ + v1.13/arm64/debian:v1.13.0-debian-arm64-1.0,v1.13-debian-arm64-1,edge-debian-arm64 \ WINDOWS_IMAGES := \ - v1.12/windows-ltsc2019:v1.12.4-windows-ltsc2019-1.0,v1.12-windows-ltsc2019-1 \ - v1.12/windows-2004:v1.12.4-windows-2004-1.0,v1.12-windows-2004-1 \ - v1.12/windows-20H2:v1.12.4-windows-20H2-1.0,v1.12-windows-20H2-1 + v1.13/windows-ltsc2019:v1.13.0-windows-ltsc2019-1.0,v1.13-windows-ltsc2019-1 \ + v1.13/windows-2004:v1.13.0-windows-2004-1.0,v1.13-windows-2004-1 \ + v1.13/windows-20H2:v1.13.0-windows-20H2-1.0,v1.13-windows-20H2-1 ALL_IMAGES := $(X86_IMAGES) $(ARM_IMAGES) $(ARM64_IMAGES) $(WINDOWS_IMAGES) diff --git a/README.md b/README.md index 6e92bb85..3fc9ae4f 100644 --- a/README.md +++ b/README.md @@ -24,19 +24,19 @@ These tags have image version postfix. This updates many places so we need feedb Current images use fluentd v1 series. -- `v1.12.4-1.0`, `v1.12-1`, `edge` +- `v1.13.0-1.0`, `v1.13-1`, `edge` [(v1.12/alpine/Dockerfile)][fluentd-1-alpine] -- `v1.12.4-debian-1.0`, `v1.12-debian-1`, `edge-debian` +- `v1.13.0-debian-1.0`, `v1.13-debian-1`, `edge-debian` [(v1.12/debian/Dockerfile)][fluentd-1-debian] -- `v1.12.4-debian-arm64-1.0`, `v1.12-debian-arm64-1`, `edge-debian-arm64` +- `v1.13.0-debian-arm64-1.0`, `v1.13-debian-arm64-1`, `edge-debian-arm64` [(v1.12/arm64/debian/Dockerfile)][fluentd-1-debian-arm64] -- `v1.12.4-debian-armhf-1.0`, `v1.12-debian-armhf-1`, `edge-debian-armhf` +- `v1.13.0-debian-armhf-1.0`, `v1.13-debian-armhf-1`, `edge-debian-armhf` [(v1.12/armhf/debian/Dockerfile)][fluentd-1-debian-armhf] -- `v1.12.4-windows-ltsc2019-1.0`, `v1.12-windows-ltsc2019-1` +- `v1.13.0-windows-ltsc2019-1.0`, `v1.13-windows-ltsc2019-1` [(v1.12/windows-ltsc2019/Dockerfile)][fluentd-1-ltsc2019-windows] -- `v1.12.4-windows-2004-1.0`, `v1.12-windows-2004-1` +- `v1.13.0-windows-2004-1.0`, `v1.13-windows-2004-1` [(v1.12/windows-2004/Dockerfile)][fluentd-1-2004-windows] -- `v1.12.4-windows-20H2-1.0`, `v1.12-windows-20H2-1` +- `v1.13.0-windows-20H2-1.0`, `v1.13-windows-20H2-1` [(v1.12/windows-20H2/Dockerfile)][fluentd-1-20H2-windows] ### Old v1.4 images @@ -224,7 +224,7 @@ To add plugins, edit `Dockerfile` as following: #### Alpine version ```Dockerfile -FROM fluent/fluentd:v1.12-1 +FROM fluent/fluentd:v1.13-1 # Use root account to use apk USER root @@ -247,7 +247,7 @@ USER fluent #### Debian version ```Dockerfile -FROM fluent/fluentd:v1.12-debian-1 +FROM fluent/fluentd:v1.13-debian-1 # Use root account to use apt USER root diff --git a/v1.13/alpine/Dockerfile b/v1.13/alpine/Dockerfile new file mode 100644 index 00000000..f9322160 --- /dev/null +++ b/v1.13/alpine/Dockerfile @@ -0,0 +1,55 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +FROM alpine:3.13 +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" + +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# This hack is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +# therefore an 'apk delete' has no effect +RUN apk update \ + && apk add --no-cache \ + ca-certificates \ + ruby ruby-irb ruby-etc ruby-webrick \ + tini \ + && apk add --no-cache --virtual .build-deps \ + build-base linux-headers \ + ruby-dev gnupg \ + && echo 'gem: --no-document' >> /etc/gemrc \ + && gem install oj -v 3.10.18 \ + && gem install json -v 2.4.1 \ + && gem install resolv -v 0.2.1 \ + && gem install async-http -v 0.54.0 \ + && gem install ext_monitor -v 0.1.2 \ + && gem install fluentd -v 1.13.0 \ + && gem install bigdecimal -v 1.4.4 \ + && apk del .build-deps \ + && rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/2.*/gems/fluentd-*/test + +RUN addgroup -S fluent && adduser -S -g fluent fluent \ + # for log storage (maybe shared with host) + && mkdir -p /fluentd/log \ + # configuration/plugins path (default: copied from .) + && mkdir -p /fluentd/etc /fluentd/plugins \ + && chown -R fluent /fluentd && chgrp -R fluent /fluentd + + +COPY fluent.conf /fluentd/etc/ +COPY entrypoint.sh /bin/ + + +ENV FLUENTD_CONF="fluent.conf" + +ENV LD_PRELOAD="" +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# Forcing to load specific version of resolv (instead of bundled by default) is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +ENV RUBYLIB="/usr/local/bundle/gems/resolv-0.2.1/lib" +EXPOSE 24224 5140 + +USER fluent +ENTRYPOINT ["tini", "--", "/bin/entrypoint.sh"] +CMD ["fluentd"] + diff --git a/v1.13/alpine/entrypoint.sh b/v1.13/alpine/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/alpine/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/alpine/fluent.conf b/v1.13/alpine/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/alpine/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/alpine/hooks/post_push b/v1.13/alpine/hooks/post_push new file mode 100755 index 00000000..f0d5c36e --- /dev/null +++ b/v1.13/alpine/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-1.0,v1.13-1,edge}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/arm64/debian/Dockerfile b/v1.13/arm64/debian/Dockerfile new file mode 100644 index 00000000..59a9bed5 --- /dev/null +++ b/v1.13/arm64/debian/Dockerfile @@ -0,0 +1,83 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +# To set multiarch build for Docker hub automated build. +FROM golang:alpine AS builder +WORKDIR /go +ENV QEMU_DOWNLOAD_SHA256 a1ef52971537e11915565233f48aa179839f676008d7911c05b3ae94c08c4f5c +RUN apk add curl --no-cache +RUN curl -sL -o qemu-3.0.0+resin-aarch64.tar.gz https://github.com/balena-io/qemu/releases/download/v3.0.0%2Bresin/qemu-3.0.0+resin-aarch64.tar.gz && echo "$QEMU_DOWNLOAD_SHA256 *qemu-3.0.0+resin-aarch64.tar.gz" | sha256sum -c - | tar zxvf qemu-3.0.0+resin-aarch64.tar.gz -C . && mv qemu-3.0.0+resin-aarch64/qemu-aarch64-static . + +FROM arm64v8/ruby:2.6-slim-buster +COPY --from=builder /go/qemu-aarch64-static /usr/bin/ +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" +ARG CROSS_BUILD_START="cross-build-start" +ARG CROSS_BUILD_END="cross-build-end" +RUN [ ${CROSS_BUILD_START} ] +ENV TINI_VERSION=0.18.0 + +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# This hack is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +# therefore an 'apt-get purge' has no effect +RUN apt-get update \ + && apt-get install -y --no-install-recommends \ + ca-certificates \ + && buildDeps=" \ + make gcc g++ libc-dev \ + wget bzip2 gnupg dirmngr \ + " \ + && apt-get install -y --no-install-recommends $buildDeps \ + && echo 'gem: --no-document' >> /etc/gemrc \ + && gem install oj -v 3.10.18 \ + && gem install json -v 2.4.1 \ + && gem install resolv -v 0.2.1 \ + && gem install async-http -v 0.54.0 \ + && gem install ext_monitor -v 0.1.2 \ + && gem install fluentd -v 1.13.0 \ + && dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')" \ + && wget -O /usr/local/bin/tini "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch" \ + && wget -O /usr/local/bin/tini.asc "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch.asc" \ + && export GNUPGHOME="$(mktemp -d)" \ + && gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 6380DC428747F6C393FEACA59A84159D7001A4E5 \ + && gpg --batch --verify /usr/local/bin/tini.asc /usr/local/bin/tini \ + && rm -r /usr/local/bin/tini.asc \ + && chmod +x /usr/local/bin/tini \ + && tini -h \ + && wget -O /tmp/jemalloc-4.5.0.tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/4.5.0/jemalloc-4.5.0.tar.bz2 \ + && cd /tmp && tar -xjf jemalloc-4.5.0.tar.bz2 && cd jemalloc-4.5.0/ \ + && ./configure && make \ + && mv lib/libjemalloc.so.2 /usr/lib \ + && apt-get purge -y --auto-remove \ + -o APT::AutoRemove::RecommendsImportant=false \ + $buildDeps \ + && rm -rf /var/lib/apt/lists/* \ + && rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/2.*/gems/fluentd-*/test + +RUN groupadd -r fluent && useradd -r -g fluent fluent \ + # for log storage (maybe shared with host) + && mkdir -p /fluentd/log \ + # configuration/plugins path (default: copied from .) + && mkdir -p /fluentd/etc /fluentd/plugins \ + && chown -R fluent /fluentd && chgrp -R fluent /fluentd + + +COPY fluent.conf /fluentd/etc/ +COPY entrypoint.sh /bin/ + + +ENV FLUENTD_CONF="fluent.conf" + +ENV LD_PRELOAD="/usr/lib/libjemalloc.so.2" +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# Forcing to load specific version of resolv (instead of bundled by default) is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +ENV RUBYLIB="/usr/local/bundle/gems/resolv-0.2.1/lib" +EXPOSE 24224 5140 + +USER fluent +ENTRYPOINT ["tini", "--", "/bin/entrypoint.sh"] +CMD ["fluentd"] + +RUN [ ${CROSS_BUILD_END} ] diff --git a/v1.13/arm64/debian/entrypoint.sh b/v1.13/arm64/debian/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/arm64/debian/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/arm64/debian/fluent.conf b/v1.13/arm64/debian/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/arm64/debian/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/arm64/debian/hooks/post_checkout b/v1.13/arm64/debian/hooks/post_checkout new file mode 100644 index 00000000..e4daef8f --- /dev/null +++ b/v1.13/arm64/debian/hooks/post_checkout @@ -0,0 +1,19 @@ +#!/bin/bash + + +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_checkout.erb + + +set -e + +HOST_ARCH=$(uname -m) + +if [ x"${HOST_ARCH}" == x"aarch64" ]; then + echo "Building arm64 image natively" + exit +fi + +# Enable cross-platform builds https://github.com/multiarch/qemu-user-static +docker run --rm --privileged multiarch/qemu-user-static:register --reset + diff --git a/v1.13/arm64/debian/hooks/post_push b/v1.13/arm64/debian/hooks/post_push new file mode 100755 index 00000000..df204a2b --- /dev/null +++ b/v1.13/arm64/debian/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-debian-arm64-1.0,v1.13-debian-arm64-1,edge-debian-arm64}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/armhf/debian/Dockerfile b/v1.13/armhf/debian/Dockerfile new file mode 100644 index 00000000..6b5c1123 --- /dev/null +++ b/v1.13/armhf/debian/Dockerfile @@ -0,0 +1,83 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +# To set multiarch build for Docker hub automated build. +FROM golang:alpine AS builder +WORKDIR /go +ENV QEMU_DOWNLOAD_SHA256 47ae430b0e7c25e1bde290ac447a720e2ea6c6e78cd84e44847edda289e020a8 +RUN apk add curl --no-cache +RUN curl -sL -o qemu-3.0.0+resin-arm.tar.gz https://github.com/balena-io/qemu/releases/download/v3.0.0%2Bresin/qemu-3.0.0+resin-arm.tar.gz && echo "$QEMU_DOWNLOAD_SHA256 *qemu-3.0.0+resin-arm.tar.gz" | sha256sum -c - | tar zxvf qemu-3.0.0+resin-arm.tar.gz -C . && mv qemu-3.0.0+resin-arm/qemu-arm-static . + +FROM arm32v7/ruby:2.6-slim-buster +COPY --from=builder /go/qemu-arm-static /usr/bin/ +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" +ARG CROSS_BUILD_START="cross-build-start" +ARG CROSS_BUILD_END="cross-build-end" +RUN [ ${CROSS_BUILD_START} ] +ENV TINI_VERSION=0.18.0 + +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# This hack is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +# therefore an 'apt-get purge' has no effect +RUN apt-get update \ + && apt-get install -y --no-install-recommends \ + ca-certificates \ + && buildDeps=" \ + make gcc g++ libc-dev \ + wget bzip2 gnupg dirmngr \ + " \ + && apt-get install -y --no-install-recommends $buildDeps \ + && echo 'gem: --no-document' >> /etc/gemrc \ + && gem install oj -v 3.10.18 \ + && gem install json -v 2.4.1 \ + && gem install resolv -v 0.2.1 \ + && gem install async-http -v 0.54.0 \ + && gem install ext_monitor -v 0.1.2 \ + && gem install fluentd -v 1.13.0 \ + && dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')" \ + && wget -O /usr/local/bin/tini "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch" \ + && wget -O /usr/local/bin/tini.asc "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch.asc" \ + && export GNUPGHOME="$(mktemp -d)" \ + && gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 6380DC428747F6C393FEACA59A84159D7001A4E5 \ + && gpg --batch --verify /usr/local/bin/tini.asc /usr/local/bin/tini \ + && rm -r /usr/local/bin/tini.asc \ + && chmod +x /usr/local/bin/tini \ + && tini -h \ + && wget -O /tmp/jemalloc-4.5.0.tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/4.5.0/jemalloc-4.5.0.tar.bz2 \ + && cd /tmp && tar -xjf jemalloc-4.5.0.tar.bz2 && cd jemalloc-4.5.0/ \ + && ./configure && make \ + && mv lib/libjemalloc.so.2 /usr/lib \ + && apt-get purge -y --auto-remove \ + -o APT::AutoRemove::RecommendsImportant=false \ + $buildDeps \ + && rm -rf /var/lib/apt/lists/* \ + && rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/2.*/gems/fluentd-*/test + +RUN groupadd -r fluent && useradd -r -g fluent fluent \ + # for log storage (maybe shared with host) + && mkdir -p /fluentd/log \ + # configuration/plugins path (default: copied from .) + && mkdir -p /fluentd/etc /fluentd/plugins \ + && chown -R fluent /fluentd && chgrp -R fluent /fluentd + + +COPY fluent.conf /fluentd/etc/ +COPY entrypoint.sh /bin/ + + +ENV FLUENTD_CONF="fluent.conf" + +ENV LD_PRELOAD="/usr/lib/libjemalloc.so.2" +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# Forcing to load specific version of resolv (instead of bundled by default) is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +ENV RUBYLIB="/usr/local/bundle/gems/resolv-0.2.1/lib" +EXPOSE 24224 5140 + +USER fluent +ENTRYPOINT ["tini", "--", "/bin/entrypoint.sh"] +CMD ["fluentd"] + +RUN [ ${CROSS_BUILD_END} ] diff --git a/v1.13/armhf/debian/entrypoint.sh b/v1.13/armhf/debian/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/armhf/debian/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/armhf/debian/fluent.conf b/v1.13/armhf/debian/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/armhf/debian/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/armhf/debian/hooks/post_checkout b/v1.13/armhf/debian/hooks/post_checkout new file mode 100644 index 00000000..51756c5e --- /dev/null +++ b/v1.13/armhf/debian/hooks/post_checkout @@ -0,0 +1,19 @@ +#!/bin/bash + + +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_checkout.erb + +set -e + +HOST_ARCH=$(uname -m) + +if [ x"${HOST_ARCH}" == x"arm*" ]; then + echo "Building armhf image natively" + exit +fi + +# Enable cross-platform builds https://github.com/multiarch/qemu-user-static +docker run --rm --privileged multiarch/qemu-user-static:register --reset + + diff --git a/v1.13/armhf/debian/hooks/post_push b/v1.13/armhf/debian/hooks/post_push new file mode 100755 index 00000000..fc7e10cd --- /dev/null +++ b/v1.13/armhf/debian/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-debian-armhf-1.0,v1.13-debian-armhf-1,edge-debian-armhf}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/debian/Dockerfile b/v1.13/debian/Dockerfile new file mode 100644 index 00000000..95db47c4 --- /dev/null +++ b/v1.13/debian/Dockerfile @@ -0,0 +1,71 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +FROM ruby:2.6-slim-buster +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" +ENV TINI_VERSION=0.18.0 + +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# This hack is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +# therefore an 'apt-get purge' has no effect +RUN apt-get update \ + && apt-get install -y --no-install-recommends \ + ca-certificates \ + && buildDeps=" \ + make gcc g++ libc-dev \ + wget bzip2 gnupg dirmngr \ + " \ + && apt-get install -y --no-install-recommends $buildDeps \ + && echo 'gem: --no-document' >> /etc/gemrc \ + && gem install oj -v 3.10.18 \ + && gem install json -v 2.4.1 \ + && gem install resolv -v 0.2.1 \ + && gem install async-http -v 0.54.0 \ + && gem install ext_monitor -v 0.1.2 \ + && gem install fluentd -v 1.13.0 \ + && dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')" \ + && wget -O /usr/local/bin/tini "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch" \ + && wget -O /usr/local/bin/tini.asc "https://github.com/krallin/tini/releases/download/v$TINI_VERSION/tini-$dpkgArch.asc" \ + && export GNUPGHOME="$(mktemp -d)" \ + && gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 6380DC428747F6C393FEACA59A84159D7001A4E5 \ + && gpg --batch --verify /usr/local/bin/tini.asc /usr/local/bin/tini \ + && rm -r /usr/local/bin/tini.asc \ + && chmod +x /usr/local/bin/tini \ + && tini -h \ + && wget -O /tmp/jemalloc-4.5.0.tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/4.5.0/jemalloc-4.5.0.tar.bz2 \ + && cd /tmp && tar -xjf jemalloc-4.5.0.tar.bz2 && cd jemalloc-4.5.0/ \ + && ./configure && make \ + && mv lib/libjemalloc.so.2 /usr/lib \ + && apt-get purge -y --auto-remove \ + -o APT::AutoRemove::RecommendsImportant=false \ + $buildDeps \ + && rm -rf /var/lib/apt/lists/* \ + && rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/2.*/gems/fluentd-*/test + +RUN groupadd -r fluent && useradd -r -g fluent fluent \ + # for log storage (maybe shared with host) + && mkdir -p /fluentd/log \ + # configuration/plugins path (default: copied from .) + && mkdir -p /fluentd/etc /fluentd/plugins \ + && chown -R fluent /fluentd && chgrp -R fluent /fluentd + + +COPY fluent.conf /fluentd/etc/ +COPY entrypoint.sh /bin/ + + +ENV FLUENTD_CONF="fluent.conf" + +ENV LD_PRELOAD="/usr/lib/libjemalloc.so.2" +# NOTE: resolv v0.2.1 includes the fix for CPU spike issue due to DNS resolver. +# Forcing to load specific version of resolv (instead of bundled by default) is needed for Ruby 2.6.7, 2.7.3 and 3.0.1. +ENV RUBYLIB="/usr/local/bundle/gems/resolv-0.2.1/lib" +EXPOSE 24224 5140 + +USER fluent +ENTRYPOINT ["tini", "--", "/bin/entrypoint.sh"] +CMD ["fluentd"] + diff --git a/v1.13/debian/entrypoint.sh b/v1.13/debian/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/debian/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/debian/fluent.conf b/v1.13/debian/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/debian/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/debian/hooks/post_push b/v1.13/debian/hooks/post_push new file mode 100755 index 00000000..02d29191 --- /dev/null +++ b/v1.13/debian/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-debian-1.0,v1.13-debian-1,edge-debian}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/windows-2004/Dockerfile b/v1.13/windows-2004/Dockerfile new file mode 100644 index 00000000..f892ace1 --- /dev/null +++ b/v1.13/windows-2004/Dockerfile @@ -0,0 +1,38 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +FROM mcr.microsoft.com/windows/servercore:2004 +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" + +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +RUN powershell -Command "Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" + +# Fluentd depends on cool.io whose fat gem is only available for Ruby < 2.5, so need to specify --platform ruby when install Ruby > 2.5 and install msys2 to get dev tools +RUN choco install -y ruby --version 2.6.5.1 --params "'/InstallDir:C:\ruby26'" \ +&& choco install -y msys2 --version 20210604.0.0 --params "'/NoPath /NoUpdate /InstallDir:C:\ruby26\msys64'" +RUN refreshenv \ +&& ridk install 2 3 \ +&& echo gem: --no-document >> C:\ProgramData\gemrc \ +&& gem install cool.io -v 1.5.4 --platform ruby \ +&& gem install oj -v 3.3.10 \ +&& gem install json -v 2.2.0 \ +&& gem install fluentd -v 1.13.0 \ +&& gem install win32-service -v 2.1.6 \ +&& gem install win32-ipc -v 0.7.0 \ +&& gem install win32-event -v 0.6.3 \ +&& gem install windows-pr -v 1.2.6 \ +&& gem sources --clear-all + +# Remove gem cache and chocolatey +RUN powershell -Command "Remove-Item -Force C:\ruby26\lib\ruby\gems\2.6.0\cache\*.gem; Remove-Item -Recurse -Force 'C:\ProgramData\chocolatey'" + +COPY fluent.conf /fluent/conf/fluent.conf + + +ENV FLUENTD_CONF="fluent.conf" + +EXPOSE 24224 5140 + +ENTRYPOINT ["cmd", "/k", "fluentd", "-c", "C:\\fluent\\conf\\fluent.conf"] diff --git a/v1.13/windows-2004/entrypoint.sh b/v1.13/windows-2004/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/windows-2004/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/windows-2004/fluent.conf b/v1.13/windows-2004/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/windows-2004/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/windows-2004/hooks/post_push b/v1.13/windows-2004/hooks/post_push new file mode 100755 index 00000000..7a33421a --- /dev/null +++ b/v1.13/windows-2004/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-windows-2004-1.0,v1.13-windows-2004-1}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/windows-20H2/Dockerfile b/v1.13/windows-20H2/Dockerfile new file mode 100644 index 00000000..2b5955ad --- /dev/null +++ b/v1.13/windows-20H2/Dockerfile @@ -0,0 +1,38 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +FROM mcr.microsoft.com/windows/servercore:20H2 +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" + +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +RUN powershell -Command "Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" + +# Fluentd depends on cool.io whose fat gem is only available for Ruby < 2.5, so need to specify --platform ruby when install Ruby > 2.5 and install msys2 to get dev tools +RUN choco install -y ruby --version 2.6.5.1 --params "'/InstallDir:C:\ruby26'" \ +&& choco install -y msys2 --version 20210604.0.0 --params "'/NoPath /NoUpdate /InstallDir:C:\ruby26\msys64'" +RUN refreshenv \ +&& ridk install 2 3 \ +&& echo gem: --no-document >> C:\ProgramData\gemrc \ +&& gem install cool.io -v 1.5.4 --platform ruby \ +&& gem install oj -v 3.3.10 \ +&& gem install json -v 2.2.0 \ +&& gem install fluentd -v 1.13.0 \ +&& gem install win32-service -v 2.1.6 \ +&& gem install win32-ipc -v 0.7.0 \ +&& gem install win32-event -v 0.6.3 \ +&& gem install windows-pr -v 1.2.6 \ +&& gem sources --clear-all + +# Remove gem cache and chocolatey +RUN powershell -Command "Remove-Item -Force C:\ruby26\lib\ruby\gems\2.6.0\cache\*.gem; Remove-Item -Recurse -Force 'C:\ProgramData\chocolatey'" + +COPY fluent.conf /fluent/conf/fluent.conf + + +ENV FLUENTD_CONF="fluent.conf" + +EXPOSE 24224 5140 + +ENTRYPOINT ["cmd", "/k", "fluentd", "-c", "C:\\fluent\\conf\\fluent.conf"] diff --git a/v1.13/windows-20H2/entrypoint.sh b/v1.13/windows-20H2/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/windows-20H2/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/windows-20H2/fluent.conf b/v1.13/windows-20H2/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/windows-20H2/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/windows-20H2/hooks/post_push b/v1.13/windows-20H2/hooks/post_push new file mode 100755 index 00000000..30df3982 --- /dev/null +++ b/v1.13/windows-20H2/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-windows-20H2-1.0,v1.13-windows-20H2-1}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done diff --git a/v1.13/windows-ltsc2019/Dockerfile b/v1.13/windows-ltsc2019/Dockerfile new file mode 100644 index 00000000..578a08c6 --- /dev/null +++ b/v1.13/windows-ltsc2019/Dockerfile @@ -0,0 +1,38 @@ +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb + +FROM mcr.microsoft.com/windows/servercore:ltsc2019 +LABEL maintainer "Fluentd developers " +LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.13.0" + +# Do not split this into multiple RUN! +# Docker creates a layer for every RUN-Statement +RUN powershell -Command "Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" + +# Fluentd depends on cool.io whose fat gem is only available for Ruby < 2.5, so need to specify --platform ruby when install Ruby > 2.5 and install msys2 to get dev tools +RUN choco install -y ruby --version 2.6.5.1 --params "'/InstallDir:C:\ruby26'" \ +&& choco install -y msys2 --version 20210604.0.0 --params "'/NoPath /NoUpdate /InstallDir:C:\ruby26\msys64'" +RUN refreshenv \ +&& ridk install 2 3 \ +&& echo gem: --no-document >> C:\ProgramData\gemrc \ +&& gem install cool.io -v 1.5.4 --platform ruby \ +&& gem install oj -v 3.3.10 \ +&& gem install json -v 2.2.0 \ +&& gem install fluentd -v 1.13.0 \ +&& gem install win32-service -v 2.1.6 \ +&& gem install win32-ipc -v 0.7.0 \ +&& gem install win32-event -v 0.6.3 \ +&& gem install windows-pr -v 1.2.6 \ +&& gem sources --clear-all + +# Remove gem cache and chocolatey +RUN powershell -Command "Remove-Item -Force C:\ruby26\lib\ruby\gems\2.6.0\cache\*.gem; Remove-Item -Recurse -Force 'C:\ProgramData\chocolatey'" + +COPY fluent.conf /fluent/conf/fluent.conf + + +ENV FLUENTD_CONF="fluent.conf" + +EXPOSE 24224 5140 + +ENTRYPOINT ["cmd", "/k", "fluentd", "-c", "C:\\fluent\\conf\\fluent.conf"] diff --git a/v1.13/windows-ltsc2019/entrypoint.sh b/v1.13/windows-ltsc2019/entrypoint.sh new file mode 100755 index 00000000..876b4244 --- /dev/null +++ b/v1.13/windows-ltsc2019/entrypoint.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +#source vars if file exists +DEFAULT=/etc/default/fluentd + +if [ -r $DEFAULT ]; then + set -o allexport + . $DEFAULT + set +o allexport +fi + +# If the user has supplied only arguments append them to `fluentd` command +if [ "${1#-}" != "$1" ]; then + set -- fluentd "$@" +fi + +# If user does not supply config file or plugins, use the default +if [ "$1" = "fluentd" ]; then + if ! echo $@ | grep ' \-c' ; then + set -- "$@" -c /fluentd/etc/${FLUENTD_CONF} + fi + + if ! echo $@ | grep ' \-p' ; then + set -- "$@" -p /fluentd/plugins + fi +fi + +exec "$@" diff --git a/v1.13/windows-ltsc2019/fluent.conf b/v1.13/windows-ltsc2019/fluent.conf new file mode 100644 index 00000000..24a37b57 --- /dev/null +++ b/v1.13/windows-ltsc2019/fluent.conf @@ -0,0 +1,33 @@ + + @type forward + @id input1 + @label @mainstream + port 24224 + + + + @type stdout + + + diff --git a/v1.13/windows-ltsc2019/hooks/post_push b/v1.13/windows-ltsc2019/hooks/post_push new file mode 100755 index 00000000..8f185237 --- /dev/null +++ b/v1.13/windows-ltsc2019/hooks/post_push @@ -0,0 +1,15 @@ +#!/bin/bash +# AUTOMATICALLY GENERATED +# DO NOT EDIT THIS FILE DIRECTLY, USE /post_push.erb + +set -e + +# Parse image name for repo name +tagStart=$(expr index "$IMAGE_NAME" :) +repoName=${IMAGE_NAME:0:tagStart-1} + +# Tag and push image for each additional tag +for tag in {v1.13.0-windows-ltsc2019-1.0,v1.13-windows-ltsc2019-1}; do + docker tag $IMAGE_NAME ${repoName}:${tag} + docker push ${repoName}:${tag} +done