Skip to content

Commit

Permalink
Merge pull request #19675 from tosi3k/log-dump-move-out
Browse files Browse the repository at this point in the history
Move log dump script and logexporter config out of kubekins directory
  • Loading branch information
k8s-ci-robot authored Oct 29, 2020
2 parents b40bcac + 823c5fc commit e927db5
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 95 deletions.
10 changes: 5 additions & 5 deletions images/kubekins-e2e/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ RUN wget -q "https://storage.googleapis.com/golang/${GO_TARBALL}" && \
# install bazel
ARG BAZEL_VERSION_ARG
ENV BAZEL_VERSION=${BAZEL_VERSION_ARG}
COPY ./install-bazel.sh /
COPY images/kubekins-e2e/install-bazel.sh /
RUN bash /install-bazel.sh

ARG OLD_BAZEL_VERSION
Expand All @@ -95,11 +95,11 @@ ARG IMAGE_ARG
ENV IMAGE=${IMAGE_ARG}

# everything below will be triggered on every new image tag ...
ADD ["kops-e2e-runner.sh", \
"kubetest", \
ADD ["images/kubekins-e2e/kops-e2e-runner.sh", \
"images/kubekins-e2e/kubetest", \
"https://raw.githubusercontent.com/kubernetes/kubernetes/master/cluster/get-kube.sh", \
"log-dump.sh", \
"logexporter-daemonset.yaml", \
"logexporter/cluster/log-dump.sh", \
"logexporter/cluster/logexporter-daemonset.yaml", \
"/workspace/"]
ENV LOG_DUMP_SCRIPT_PATH "/workspace/log-dump.sh"
RUN ["chmod", "+x", "/workspace/get-kube.sh", "/workspace/log-dump.sh"]
6 changes: 4 additions & 2 deletions images/kubekins-e2e/cloudbuild.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,16 @@ steps:
- --build-arg=K8S_RELEASE=$_K8S_RELEASE
- --build-arg=OLD_BAZEL_VERSION=$_OLD_BAZEL_VERSION
- --build-arg=UPGRADE_DOCKER_ARG=$_UPGRADE_DOCKER
- -f
- images/kubekins-e2e/Dockerfile
- .
dir: images/kubekins-e2e
dir: .
- name: gcr.io/cloud-builders/docker
args:
- tag
- gcr.io/$PROJECT_ID/kubekins-e2e:$_GIT_TAG-$_CONFIG
- gcr.io/$PROJECT_ID/kubekins-e2e:latest-$_CONFIG
dir: images/kubekins-e2e
dir: .
substitutions:
_BAZEL_VERSION: 3.4.1
_OLD_BAZEL_VERSION: 2.2.0
Expand Down
81 changes: 0 additions & 81 deletions images/kubekins-e2e/logexporter-daemonset.yaml

This file was deleted.

File renamed without changes.
20 changes: 13 additions & 7 deletions logexporter/cluster/logexporter-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,31 +9,34 @@
apiVersion: v1
kind: Namespace
metadata:
name: logexporter
name: {{.LogexporterNamespace}}
---
apiVersion: v1
kind: Secret
metadata:
name: google-service-account
namespace: logexporter
namespace: {{.LogexporterNamespace}}
type: Opaque
data:
service-account.json: {{.ServiceAccountCredentials}}
---
apiVersion: extensions/v1beta1
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: logexporter
namespace: logexporter
namespace: {{.LogexporterNamespace}}
spec:
selector:
matchLabels:
app: logexporter
template:
metadata:
labels:
app: logexporter
spec:
containers:
- name: logexporter-test
image: gcr.io/k8s-testimages/logexporter:v0.1.6
image: gcr.io/k8s-testimages/logexporter:v20200401-c3269f485
env:
- name: NODE_NAME
valueFrom:
Expand All @@ -46,9 +49,10 @@ spec:
- --gcs-path={{.GCSPath}}
- --gcloud-auth-file-path=/etc/service-account/service-account.json
- --enable-hollow-node-logs={{.EnableHollowNodeLogs}}
- --journal-path=/var/log/journal
- --dump-systemd-journal={{.DumpSystemdJournal}}
- --extra-log-files={{.ExtraLogFiles}}
- --extra-systemd-services={{.ExtraSystemdServices}}
- --sleep-duration=24h
- --alsologtostderr
volumeMounts:
- mountPath: /etc/service-account
name: service
Expand All @@ -63,6 +67,8 @@ spec:
requests:
cpu: 10m
memory: 10Mi
nodeSelector:
{{.NodeSelector}}
volumes:
- name: service
secret:
Expand Down

0 comments on commit e927db5

Please sign in to comment.