Skip to content

Commit

Permalink
Merge pull request #561 from wenchajun/wenchajun/release-2.0.1
Browse files Browse the repository at this point in the history
release 2.0.1
  • Loading branch information
benjaminhuo committed Feb 8, 2023
2 parents 3c75d3d + 6b46ade commit cc870c4
Show file tree
Hide file tree
Showing 27 changed files with 78 additions and 60 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-fb-image.yaml
Expand Up @@ -13,7 +13,7 @@ on:
- "pkg/filenotify/**"

env:
FB_IMG: 'kubesphere/fluent-bit:v2.0.8'
FB_IMG: 'kubesphere/fluent-bit:v2.0.9'

jobs:
build:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-fd-image.yaml
Expand Up @@ -13,9 +13,9 @@ on:
- "pkg/filenotify/**"

env:
FD_IMG: 'kubesphere/fluentd:v1.14.6'
FD_IMG: 'kubesphere/fluentd:v1.15.3'
ARCH: '-arm64'
FD_IMG_BASE: 'kubesphere/fluentd:v1.14.6-arm64-base'
FD_IMG_BASE: 'kubesphere/fluentd:v1.15.3-arm64-base'

jobs:
build-amd64:
Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,11 @@
## 2.0.1 / 2023-02-08
### ENHANCEMENT
- Upgrade Fluentd to v1.15.3 (#556)
- Upgrade Fluentbit to v2.0.9 (#557)

### BUGFIX
- Fix: Fix the bug of adding `label` (#548)

## 2.0.0 / 2023-02-03
### Features
- Feat: Support adding annotations to the fluent-operator deployment (#467)
Expand Down
6 changes: 3 additions & 3 deletions Makefile
@@ -1,9 +1,9 @@
VERSION?=$(shell cat VERSION | tr -d " \t\n\r")
# Image URL to use all building/pushing image targets
FB_IMG ?= kubesphere/fluent-bit:v2.0.8
FD_IMG ?= kubesphere/fluentd:v1.14.6
FB_IMG ?= kubesphere/fluent-bit:v2.0.9
FD_IMG ?= kubesphere/fluentd:v1.15.3
FO_IMG ?= kubesphere/fluent-operator:$(VERSION)
FD_IMG_BASE ?= kubesphere/fluentd:v1.14.6-arm64-base
FD_IMG_BASE ?= kubesphere/fluentd:v1.15.3-arm64-base

ARCH ?= arm64

Expand Down
1 change: 1 addition & 0 deletions RELEASE.md
Expand Up @@ -32,6 +32,7 @@ This page describes the release process and the currently planned schedule for u
| v1.6.1 | 2022-10-31 | Elon Cheng (GitHub: @wenchajun) |
| v1.7.0 | 2022-11-23 | Elon Cheng (GitHub: @wenchajun) |
| v2.0.0 | 2023-02-03 | Elon Cheng (GitHub: @wenchajun) |
| v2.0.1 | 2023-02-08 | Elon Cheng (GitHub: @wenchajun) |

# How to cut a new release

Expand Down
2 changes: 1 addition & 1 deletion VERSION
@@ -1 +1 @@
v2.0.0
v2.0.1
4 changes: 2 additions & 2 deletions charts/fluent-operator/Chart.yaml
Expand Up @@ -15,9 +15,9 @@ description: A Helm chart for Kubernetes
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 2.0.0
version: 2.0.2

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
appVersion: 2.0.0
appVersion: 2.0.1
6 changes: 3 additions & 3 deletions charts/fluent-operator/values.yaml
Expand Up @@ -16,7 +16,7 @@ operator:
tag: "20.10"
container:
repository: "kubesphere/fluent-operator"
tag: "v2.0.0"
tag: "v2.0.1"
# FluentBit operator resources. Usually user needn't to adjust these.
resources:
limits:
Expand All @@ -42,7 +42,7 @@ operator:
fluentbit:
image:
repository: "kubesphere/fluent-bit"
tag: "v2.0.8"
tag: "v2.0.9"
# fluentbit resources. If you do want to specify resources, adjust them as necessary
#You can adjust it based on the log volume.
resources:
Expand Down Expand Up @@ -166,7 +166,7 @@ fluentd:
port: 24224
image:
repository: "kubesphere/fluentd"
tag: "v1.14.6"
tag: "v1.15.3"
replicas: 1
forward:
port: 24224
Expand Down
2 changes: 1 addition & 1 deletion cmd/fluent-watcher/fluentbit/Dockerfile
Expand Up @@ -6,7 +6,7 @@ WORKDIR /code
RUN echo $(ls -al /code)
RUN CGO_ENABLED=0 go build -i -ldflags '-w -s' -o /fluent-bit/fluent-bit /code/cmd/fluent-watcher/fluentbit/main.go

FROM fluent/fluent-bit:2.0.8
FROM fluent/fluent-bit:2.0.9
LABEL Description="Fluent Bit docker image" Vendor="Fluent" Version="1.0"

COPY conf/fluent-bit.conf conf/parsers.conf /fluent-bit/etc/
Expand Down
14 changes: 7 additions & 7 deletions cmd/fluent-watcher/fluentd/Dockerfile.amd64
Expand Up @@ -8,8 +8,8 @@ RUN echo $(ls -al /code)
RUN CGO_ENABLED=0 go build -i -ldflags '-w -s' -o /fluentd/fluentd-watcher /code/cmd/fluent-watcher/fluentd/main.go

# Fluentd main image
FROM alpine:3.13
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.14.6"
FROM alpine:3.16
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.15.3"

# Do not split this into multiple RUN!
# Docker creates a layer for every RUN-Statement
Expand All @@ -23,11 +23,11 @@ RUN apk update \
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 async-http -v 0.54.0 \
&& gem install ext_monitor -v 0.1.2 \
&& gem install fluentd -v 1.14.6 \
&& gem install oj -v 3.13.22 \
&& gem install json -v 2.6.2 \
&& gem install async -v 1.30.3 \
&& gem install async-http -v 0.56.6 \
&& gem install fluentd -v 1.15.3 \
&& gem install bigdecimal -v 1.4.4 \
# 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. (alpine image is still kept on 2.7.3)
Expand Down
19 changes: 10 additions & 9 deletions cmd/fluent-watcher/fluentd/Dockerfile.arm64
Expand Up @@ -15,9 +15,9 @@ RUN apk add curl --no-cache
RUN curl -sL -o qemu-6.0.0.balena1-aarch64.tar.gz https://github.com/balena-io/qemu/releases/download/v6.0.0%2Bbalena1/qemu-6.0.0.balena1-aarch64.tar.gz && echo "$QEMU_DOWNLOAD_SHA256 *qemu-6.0.0.balena1-aarch64.tar.gz" | sha256sum -c - | tar zxvf qemu-6.0.0.balena1-aarch64.tar.gz -C . && mv qemu-6.0.0+balena1-aarch64/qemu-aarch64-static .

# Fluentd main image
FROM arm64v8/ruby:2.7-slim-bullseye
FROM arm64v8/ruby:3.1-slim-bullseye
COPY --from=builderqemu /go/qemu-aarch64-static /usr/bin/
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.14.6"
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.15.3"
ENV TINI_VERSION=0.18.0

# Do not split this into multiple RUN!
Expand All @@ -32,11 +32,12 @@ RUN apt-get update \
" \
&& 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 async-http -v 0.54.0 \
&& gem install ext_monitor -v 0.1.2 \
&& gem install fluentd -v 1.14.6 \
&& gem install oj -v 3.13.22 \
&& gem install json -v 2.6.2 \
&& gem install rexml -v 3.2.5 \
&& gem install async -v 1.30.3 \
&& gem install async-http -v 0.56.6 \
&& gem install fluentd -v 1.15.3 \
&& gem install bigdecimal -v 1.4.4 \
&& gem install resolv -v 0.2.1 \
&& gem install elasticsearch -v 7.13.3 \
Expand All @@ -55,8 +56,8 @@ RUN apt-get update \
fluent-plugin-aws-elasticsearch-service \
fluent-plugin-opensearch \
&& echo "plugin installed." \
&& 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/ \
&& wget -O /tmp/jemalloc-5.3.0.tar.bz2 https://github.com/jemalloc/jemalloc/releases/download/5.3.0/jemalloc-5.3.0.tar.bz2 \
&& cd /tmp && tar -xjf jemalloc-5.3.0.tar.bz2 && cd jemalloc-5.3.0/ \
&& ./configure && make \
&& mv lib/libjemalloc.so.2 /usr/lib \
&& apt-get purge -y --auto-remove \
Expand Down
13 changes: 7 additions & 6 deletions cmd/fluent-watcher/fluentd/Dockerfile.arm64.base
Expand Up @@ -6,9 +6,9 @@ RUN apk add curl --no-cache
RUN curl -sL -o qemu-6.0.0.balena1-aarch64.tar.gz https://github.com/balena-io/qemu/releases/download/v6.0.0%2Bbalena1/qemu-6.0.0.balena1-aarch64.tar.gz && echo "$QEMU_DOWNLOAD_SHA256 *qemu-6.0.0.balena1-aarch64.tar.gz" | sha256sum -c - | tar zxvf qemu-6.0.0.balena1-aarch64.tar.gz -C . && mv qemu-6.0.0+balena1-aarch64/qemu-aarch64-static .

# Fluentd main image
FROM arm64v8/ruby:2.7-slim-bullseye
FROM arm64v8/ruby:3.1-slim-bullseye
COPY --from=builderqemu /go/qemu-aarch64-static /usr/bin/
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.14.6"
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.15.3"
ENV TINI_VERSION=0.18.0

# Do not split this into multiple RUN!
Expand All @@ -23,10 +23,11 @@ RUN apt-get update \
" \
&& 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 async-http -v 0.54.0 \
&& gem install ext_monitor -v 0.1.2 \
&& gem install oj -v 3.13.22 \
&& gem install json -v 2.6.2 \
&& gem install rexml -v 3.2.5 \
&& gem install async -v 1.30.3 \
&& gem install async-http -v 0.56.6 \
&& gem install bigdecimal -v 1.4.4 \
&& gem install resolv -v 0.2.1 \
&& gem install elasticsearch -v 7.13.3 \
Expand Down
6 changes: 3 additions & 3 deletions cmd/fluent-watcher/fluentd/Dockerfile.arm64.quick
Expand Up @@ -8,8 +8,8 @@ RUN echo $(ls -al /code)
RUN CGO_ENABLED=0 go build -i -ldflags '-w -s' -o /fluentd/fluentd-watcher /code/cmd/fluent-watcher/fluentd/main.go

# Fluentd main image
FROM kubesphere/fluentd:v1.14.6-arm64-base
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.14.6"
FROM kubesphere/fluentd:v1.15.3-arm64-base
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.15.3"
ENV TINI_VERSION=0.18.0

# Do not split this into multiple RUN!
Expand All @@ -19,7 +19,7 @@ RUN buildDeps=" \
make gcc g++ libc-dev \
wget bzip2 gnupg dirmngr\
" \
&& gem install fluentd -v 1.14.6 \
&& gem install fluentd -v 1.15.3 \
&& apt-get purge -y --auto-remove \
-o APT::AutoRemove::RecommendsImportant=false \
$buildDeps \
Expand Down
15 changes: 8 additions & 7 deletions cmd/fluent-watcher/fluentd/base/Dockerfile
Expand Up @@ -2,7 +2,7 @@
# DO NOT EDIT THIS FILE DIRECTLY, USE /Dockerfile.template.erb

FROM alpine:3.17.1
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.14.6"
LABEL Description="Fluentd docker image" Vendor="Fluent Organization" Version="1.15.3"

# Do not split this into multiple RUN!
# Docker creates a layer for every RUN-Statement
Expand All @@ -16,11 +16,12 @@ RUN apk update \
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 async-http -v 0.54.0 \
&& gem install ext_monitor -v 0.1.2 \
&& gem install fluentd -v 1.14.6 \
&& gem install oj -v 3.13.22 \
&& gem install json -v 2.6.2 \
&& gem install rexml -v 3.2.5 \
&& gem install async -v 1.30.3 \
&& gem install async-http -v 0.56.6 \
&& gem install fluentd -v 1.15.3 \
&& gem install bigdecimal -v 1.4.4 \
# 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. (alpine image is still kept on 2.7.3)
Expand All @@ -42,7 +43,7 @@ RUN apk update \
fluent-plugin-opensearch \
fluent-plugin-grafana-loki \
&& apk del .build-deps \
&& rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/2.*/gems/fluentd-*/test
&& rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem /usr/lib/ruby/gems/3.*/gems/fluentd-*/test

RUN addgroup -S fluent && adduser -S -G fluent fluent \
# for log storage (maybe shared with host)
Expand Down
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 3
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
2 changes: 1 addition & 1 deletion manifests/fluentd/fluentd-cluster-cfg-output-es.yaml
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 1
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
2 changes: 1 addition & 1 deletion manifests/fluentd/fluentd-cluster-cfg-output-kafka.yaml
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 1
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 1
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
2 changes: 1 addition & 1 deletion manifests/fluentd/fluentd-mixed-cfgs-output-es.yaml
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 1
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
2 changes: 1 addition & 1 deletion manifests/fluentd/fluentd-namespaced-cfg-output-es.yaml
Expand Up @@ -11,7 +11,7 @@ spec:
bind: 0.0.0.0
port: 24224
replicas: 1
image: kubesphere/fluentd:v1.14.6
image: kubesphere/fluentd:v1.15.3
fluentdCfgSelector:
matchLabels:
config.fluentd.fluent.io/enabled: "true"
Expand Down
2 changes: 1 addition & 1 deletion manifests/kubeedge/fluentbit-fluentbit-edge.yaml
Expand Up @@ -6,7 +6,7 @@ metadata:
labels:
app.kubernetes.io/name: fluent-bit
spec:
image: kubesphere/fluent-bit:v2.0.8
image: kubesphere/fluent-bit:v2.0.9
positionDB:
hostPath:
path: /var/lib/fluent-bit/
Expand Down
2 changes: 1 addition & 1 deletion manifests/logging-stack/fluentbit-fluentBit.yaml
Expand Up @@ -6,7 +6,7 @@ metadata:
labels:
app.kubernetes.io/name: fluent-bit
spec:
image: kubesphere/fluent-bit:v2.0.8
image: kubesphere/fluent-bit:v2.0.9
positionDB:
hostPath:
path: /var/lib/fluent-bit/
Expand Down
2 changes: 1 addition & 1 deletion manifests/quick-start/fluentbit.yaml
Expand Up @@ -6,7 +6,7 @@ metadata:
labels:
app.kubernetes.io/name: fluent-bit
spec:
image: kubesphere/fluent-bit:v2.0.8
image: kubesphere/fluent-bit:v2.0.9
fluentBitConfigName: fluent-bit-config

---
Expand Down
2 changes: 1 addition & 1 deletion manifests/regex-parser/fluentbit-fluentBit.yaml
Expand Up @@ -6,5 +6,5 @@ metadata:
labels:
app.kubernetes.io/name: fluent-bit
spec:
image: kubesphere/fluent-bit:v2.0.8
image: kubesphere/fluent-bit:v2.0.9
fluentBitConfigName: fluent-bit-config
2 changes: 1 addition & 1 deletion manifests/setup/fluent-operator-deployment.yaml
Expand Up @@ -39,7 +39,7 @@ spec:
mountPath: /var/run/docker.sock
containers:
- name: fluent-operator
image: kubesphere/fluent-operator:v2.0.0
image: kubesphere/fluent-operator:v2.0.1
env:
- name: NAMESPACE
valueFrom:
Expand Down
2 changes: 1 addition & 1 deletion manifests/setup/setup.yaml
Expand Up @@ -18764,7 +18764,7 @@ spec:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
image: kubesphere/fluent-operator:v2.0.0
image: kubesphere/fluent-operator:v2.0.1
name: fluent-operator
resources:
limits:
Expand Down
12 changes: 9 additions & 3 deletions pkg/operator/daemonset.go
Expand Up @@ -11,22 +11,28 @@ import (
)

func MakeDaemonSet(fb fluentbitv1alpha2.FluentBit, logPath string) appsv1.DaemonSet {
var labels map[string]string
if fb.Spec.Labels != nil {
labels = fb.Spec.Labels
} else {
labels = fb.Labels
}
ds := appsv1.DaemonSet{
ObjectMeta: metav1.ObjectMeta{
Name: fb.Name,
Namespace: fb.Namespace,
Labels: fb.Labels,
Labels: labels,
Annotations: fb.Annotations,
},
Spec: appsv1.DaemonSetSpec{
Selector: &metav1.LabelSelector{
MatchLabels: fb.Labels,
MatchLabels: labels,
},
Template: corev1.PodTemplateSpec{
ObjectMeta: metav1.ObjectMeta{
Name: fb.Name,
Namespace: fb.Namespace,
Labels: fb.Spec.Labels,
Labels: labels,
Annotations: fb.Spec.Annotations,
},
Spec: corev1.PodSpec{
Expand Down

0 comments on commit cc870c4

Please sign in to comment.