Skip to content
This repository was archived by the owner on Sep 26, 2025. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/build_and_push_to_dockerhub.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
set -e
echo "Building docker image..."
cp /tmp/pkg/fluent-plugin-kubernetes-metrics-*.gem docker
VERSION=`cat VERSION`
echo "Copying licenses to be included in the docker image..."
mkdir docker/licenses
cp -rp LICENSE docker/licenses/
VERSION=`cat VERSION`
docker build --build-arg VERSION=$VERSION --no-cache -t splunk/fluent-plugin-kubernetes-metrics:ci ./docker
docker tag splunk/fluent-plugin-kubernetes-metrics:ci splunk/${DOCKERHUB_REPO_NAME}:${VERSION}
docker tag splunk/fluent-plugin-kubernetes-metrics:ci splunk/${DOCKERHUB_REPO_NAME}:latest
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pkg
coverage/
.idea/
docker/gems/
docker/gem/
docker/licenses/
/.bundle/
docker/.bundle/
2 changes: 1 addition & 1 deletion CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Fluentd Plugin for Kubernetes Metrics is developed by Splunkers and the open-source community.

We thank all of our [contributors](https://github.com/splunk/fluent-plugin-kubernetes-objects/graphs/contributors)!
We thank all of our [contributors](https://github.com/splunk/fluent-plugin-kubernetes-metrics/graphs/contributors)!

**For the detailed history of contributions** of a given file, try

Expand Down
1 change: 0 additions & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ namespace :docker do
task :build, [:tag] => :build do |_t, args|
raise 'Argument `tag` was not provided.' unless args.tag

cp Dir['pkg/fluent-plugin-kubernetes-metrics-*.gem'], 'docker/'
sh "docker build --build-arg VERSION=$(cat VERSION) --no-cache -t splunk/connect-for-kubernetes:#{args.tag} ./docker"
end
end
8 changes: 4 additions & 4 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ COPY licenses /licenses

COPY Gemfile* ./
RUN gem install bundler \
&& bundle install \
&& bundle exec gem install /tmp/*.gem
&& gem unpack /tmp/*.gem --target gem \
&& bundle install

RUN groupadd -r $FLUENT_USER && \
useradd -r -g $FLUENT_USER $FLUENT_USER && \
mkdir -p /fluentd/log fluentd/etc /fluentd/plugins &&\
mkdir -p /fluentd/log /fluentd/etc /fluentd/plugins && \
chown -R $FLUENT_USER /fluentd && chgrp -R $FLUENT_USER /fluentd

USER $FLUENT_USER
CMD exec fluentd -c /fluentd/etc/fluent.conf
CMD bundle exec fluentd -c /fluentd/etc/fluent.conf
2 changes: 2 additions & 0 deletions docker/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,5 @@ gem 'kubeclient', '=4.6.0'
gem 'http_parser.rb', '=0.5.3'

gem "fluent-plugin-splunk-hec", "= 1.2.1"

gem "fluent-plugin-kubernetes-metrics", path: "gem/"
11 changes: 11 additions & 0 deletions docker/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
PATH
remote: gem
specs:
fluent-plugin-kubernetes-metrics (1.1.3)
fluentd (~> 1.9.1)
http_parser.rb (= 0.5.3)
kubeclient (~> 4.6.0)
multi_json (~> 1.14.1)
oj (~> 3.10.2)

GEM
remote: https://rubygems.org/
specs:
Expand Down Expand Up @@ -152,6 +162,7 @@ PLATFORMS
DEPENDENCIES
bigdecimal (= 2.0.0)
fluent-plugin-jq (= 0.5.1)
fluent-plugin-kubernetes-metrics!
fluent-plugin-prometheus (= 1.7.0)
fluent-plugin-record-modifier (= 2.1.0)
fluent-plugin-splunk-hec (= 1.2.1)
Expand Down
2 changes: 1 addition & 1 deletion docker/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Docker Image for Splunk Connect for Kubernetes
Fluentd with input plugin for k8s metrics
# To Build
`docker build --build-arg VERSION=$(cat VERSION) --no-cache -t splunk/fluent-plugin-kubernetes-metrics:ci ./docker`
`docker build --build-arg VERSION=$(cat VERSION) -t splunk/splunk/k8s-metrics:local ./docker`
2 changes: 1 addition & 1 deletion docker/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ VERSION=`cat VERSION`
echo "Copying licenses to be included in the docker image..."
mkdir -p docker/licenses
cp -rp LICENSE docker/licenses/
docker build --build-arg VERSION=$VERSION --no-cache -t splunk/k8s-metrics:$TAG ./docker
docker build --build-arg VERSION=$VERSION --no-cache -t splunk/k8s-metrics:$TAG ./docker