Skip to content

Commit bd17499

Browse files
author
Workshop User
committed
add fargate-fluentbit chart
Signed-off-by: Workshop User <[email protected]>
1 parent d3661ba commit bd17499

File tree

5 files changed

+160
-0
lines changed

5 files changed

+160
-0
lines changed
+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*.orig
18+
*~
19+
# Various IDEs
20+
.project
21+
.idea/
22+
*.tmproj
23+
.vscode/
+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
apiVersion: v2
2+
name: aws-fargate-fluentbit
3+
description: A Helm chart AWS Fargate FluentBit
4+
5+
# A chart can be either an 'application' or a 'library' chart.
6+
#
7+
# Application charts are a collection of templates that can be packaged into versioned archives
8+
# to be deployed.
9+
#
10+
# Library charts provide useful utilities or functions for the chart developer. They're included as
11+
# a dependency of application charts to inject those utilities and functions into the rendering
12+
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
13+
type: application
14+
15+
# This is the chart version. This version number should be incremented each time you make changes
16+
# to the chart and its templates, including the app version.
17+
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18+
version: 1.0.0
19+
20+
# This is the version number of the application being deployed. This version number should be
21+
# incremented each time you make changes to the application. Versions are not expected to
22+
# follow Semantic Versioning. They should reflect the version the application is using.
23+
# It is recommended to use it with quotes.
24+
appVersion: "1.0.0"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
{{/*
2+
Expand the name of the chart.
3+
*/}}
4+
{{- define "resources.name" -}}
5+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
6+
{{- end }}
7+
8+
{{/*
9+
Create a default fully qualified app name.
10+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
11+
If release name contains chart name it will be used as a full name.
12+
*/}}
13+
{{- define "resources.fullname" -}}
14+
{{- if .Values.fullnameOverride }}
15+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
16+
{{- else }}
17+
{{- $name := default .Chart.Name .Values.nameOverride }}
18+
{{- if contains $name .Release.Name }}
19+
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
20+
{{- else }}
21+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
22+
{{- end }}
23+
{{- end }}
24+
{{- end }}
25+
26+
{{/*
27+
Create chart name and version as used by the chart label.
28+
*/}}
29+
{{- define "resources.chart" -}}
30+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
31+
{{- end }}
32+
33+
{{/*
34+
Common labels
35+
*/}}
36+
{{- define "resources.labels" -}}
37+
helm.sh/chart: {{ include "resources.chart" . }}
38+
{{ include "resources.selectorLabels" . }}
39+
{{- if .Chart.AppVersion }}
40+
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
41+
{{- end }}
42+
app.kubernetes.io/managed-by: {{ .Release.Service }}
43+
{{- end }}
44+
45+
{{/*
46+
Selector labels
47+
*/}}
48+
{{- define "resources.selectorLabels" -}}
49+
app.kubernetes.io/name: {{ include "resources.name" . }}
50+
app.kubernetes.io/instance: {{ .Release.Name }}
51+
{{- end }}
52+
53+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{{- if .Values.enabled }}
2+
kind: Namespace
3+
apiVersion: v1
4+
metadata:
5+
name: aws-observability
6+
labels:
7+
aws-observability: enabled
8+
---
9+
kind: ConfigMap
10+
apiVersion: v1
11+
metadata:
12+
name: aws-logging
13+
namespace: aws-observability
14+
data:
15+
parsers.conf: |
16+
{{ .Values.parser | indent 4 }}
17+
filters.conf: |
18+
{{ .Values.filters | indent 4 }}
19+
output.conf: |
20+
{{ tpl .Values.output $ | indent 4 }}
21+
flb_log_cw: {{ .Values.flb_log_cw | quote }}
22+
23+
{{- end }}
+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
enabled: true
2+
3+
parser: |
4+
[PARSER]
5+
Name regex
6+
Format regex
7+
Regex ^(?<time>[^ ]+) (?<stream>[^ ]+) (?<logtag>[^ ]+) (?<message>.+)$
8+
Time_Key time
9+
Time_Format %Y-%m-%dT%H:%M:%S.%L%z
10+
Time_Keep On
11+
Decode_Field_As json message
12+
13+
filters: |
14+
[FILTER]
15+
Name parser
16+
Match *
17+
Key_Name log
18+
Parser regex
19+
Preserve_Key True
20+
Reserve_Data True
21+
22+
output: |
23+
[OUTPUT]
24+
Name cloudwatch_logs
25+
Match *
26+
region {{ .Values.region }}
27+
log_group_name {{ .Values.log_group_name }}
28+
log_stream_prefix {{ .Values.log_stream_prefix }}
29+
auto_create_group true
30+
31+
flb_log_cw: "false"
32+
33+
log_group_name: "replace_with_valid_log_group"
34+
35+
log_stream_prefix: "fargate-logs-"
36+
37+
region: "us-east-1"

0 commit comments

Comments
 (0)