Skip to content

Commit 7c90c92

Browse files
authored
Merge pull request #49 from lightrun-platform/DEVOPS-2694-security-lightrun-installer-container-must-not-consume-secrets-as-env-vars-REVERT
Revert "Merge pull request #46 from lightrun-platform/DEVOPS-2694-sec…
2 parents 839f305 + c520f99 commit 7c90c92

File tree

14 files changed

+110
-265
lines changed

14 files changed

+110
-265
lines changed

.github/workflows/tests_data/lightrunjavaagent.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ spec:
1010
deploymentName: sample-deployment
1111
secretName: lightrun-secrets
1212
serverHostname: dogfood.internal.lightrun.com
13-
useSecretsAsMountedFiles: false
1413
agentEnvVarName: JAVA_TOOL_OPTIONS
1514
agentConfig:
1615
max_log_cpu_cost: "2"

api/v1beta/lightrunjavaagent_types.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,6 @@ type LightrunJavaAgentSpec struct {
9393
// +optional
9494
// Agent name for registration to the server
9595
AgentName string `json:"agentName,omitempty"`
96-
97-
// UseSecretsAsMountedFiles determines whether to use secret values as mounted files (true) or as environment variables (false)
98-
// +kubebuilder:default=false
99-
UseSecretsAsMountedFiles bool `json:"useSecretsAsMountedFiles,omitempty"`
10096
}
10197

10298
// LightrunJavaAgentStatus defines the observed state of LightrunJavaAgent

charts/lightrun-agents/templates/java-agent-cr.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ spec:
2929
secretName: {{ .name }}-secret
3030
{{- end }}
3131
serverHostname: {{ .serverHostname }}
32-
{{- if .useSecretsAsMountedFiles }}
33-
useSecretsAsMountedFiles: {{ .useSecretsAsMountedFiles | default false }}
34-
{{- end }}
3532
agentEnvVarName: {{ .agentEnvVarName | default "JAVA_TOOL_OPTIONS" }}
3633
{{- if .agentConfig }}
3734
agentConfig: {{ toYaml .agentConfig | nindent 4 }}

charts/lightrun-agents/values.yaml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ javaAgents: []
1919
# containerSelector:
2020
# - my-container-1
2121
# serverHostname: 'lightrun.example.com'
22-
# useSecretsAsMountedFiles: false
2322
# initContainer:
2423
# image: "lightruncom/k8s-operator-init-java-agent-linux:latest"
2524
# imagePullPolicy: "IfNotPresent"
@@ -43,7 +42,6 @@ javaAgents: []
4342
# containerSelector:
4443
# - my-container-2
4544
# serverHostname: 'lightrun.example.com'
46-
# useSecretsAsMountedFiles: false
4745
# agentPoolCredentials:
4846
# existingSecret: "my-existing-secret"
4947
# apiKey: ""
@@ -71,7 +69,6 @@ javaAgents: []
7169
# containerSelector:
7270
# - my-container-1
7371
# serverHostname: 'lightrun.example.com'
74-
# useSecretsAsMountedFiles: false
7572
# agentEnvVarName: '_JAVA_OPTIONS'
7673
# agentConfig:
7774
# max_log_cpu_cost: "2"
@@ -103,7 +100,6 @@ javaAgents: []
103100
# containerSelector:
104101
# - my-container-2
105102
# serverHostname: 'lightrun.example.com'
106-
# useSecretsAsMountedFiles: false
107103
# agentEnvVarName: 'JAVA_OPTS'
108104
# agentConfig:
109105
# max_log_cpu_cost: "2"

charts/lightrun-operator/crds/lightrunjavaagent_crd.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,11 +123,6 @@ spec:
123123
Lightrun server hostname that will be used for downloading an agent
124124
Key and company id in the secret has to be taken from this server as well
125125
type: string
126-
useSecretsAsMountedFiles:
127-
default: false
128-
description: UseSecretsAsMountedFiles determines whether to use secret
129-
values as mounted files (true) or as environment variables (false)
130-
type: boolean
131126
workloadName:
132127
description: Name of the Workload that will be patched. workload can
133128
be either Deployment or StatefulSet e.g. my-deployment, my-statefulset

config/crd/bases/agents.lightrun.com_lightrunjavaagents.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -124,11 +124,6 @@ spec:
124124
Lightrun server hostname that will be used for downloading an agent
125125
Key and company id in the secret has to be taken from this server as well
126126
type: string
127-
useSecretsAsMountedFiles:
128-
default: false
129-
description: UseSecretsAsMountedFiles determines whether to use secret
130-
values as mounted files (true) or as environment variables (false)
131-
type: boolean
132127
workloadName:
133128
description: Name of the Workload that will be patched. workload can
134129
be either Deployment or StatefulSet e.g. my-deployment, my-statefulset

config/samples/agents_v1beta_lightrunjavaagent.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ spec:
1111
workloadType: Deployment
1212
secretName: lightrun-secrets
1313
serverHostname: <lightrun_server> #for saas it will be app.lightrun.com
14-
useSecretsAsMountedFiles: false
1514
agentEnvVarName: JAVA_TOOL_OPTIONS
1615
agentConfig:
1716
max_log_cpu_cost: "2"

config/samples/operator.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -135,11 +135,6 @@ spec:
135135
Lightrun server hostname that will be used for downloading an agent
136136
Key and company id in the secret has to be taken from this server as well
137137
type: string
138-
useSecretsAsMountedFiles:
139-
default: false
140-
description: UseSecretsAsMountedFiles determines whether to use secret
141-
values as mounted files (true) or as environment variables (false)
142-
type: boolean
143138
workloadName:
144139
description: Name of the Workload that will be patched. workload can
145140
be either Deployment or StatefulSet e.g. my-deployment, my-statefulset

docs/custom_resource.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ spec:
5151
# If container not mentioned here it will be not patched
5252
containerSelector:
5353
- app
54-
# useSecretsAsMountedFiles determines whether to use secret values as environment variables (false) or as mounted files (true)
55-
# Default is false for backward compatibility
56-
useSecretsAsMountedFiles: false
5754
---
5855
apiVersion: v1
5956
metadata:

examples/lightrunjavaagent.yaml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,3 @@ spec:
6161
- latest
6262
# Agent name. If not provided, pod name will be used
6363
#agentName: "operator-test-agent"
64-
65-
# UseSecretsAsMountedFiles determines whether to use secret values as mounted files (true) or as environment variables (false)
66-
# Default is false for better security practices
67-
useSecretsAsMountedFiles: false

examples/operator.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -125,11 +125,6 @@ spec:
125125
Lightrun server hostname that will be used for downloading an agent
126126
Key and company id in the secret has to be taken from this server as well
127127
type: string
128-
useSecretsAsMountedFiles:
129-
default: false
130-
description: UseSecretsAsMountedFiles determines whether to use secret
131-
values as mounted files (true) or as environment variables (false)
132-
type: boolean
133128
workloadName:
134129
description: Name of the Workload that will be patched. workload can
135130
be either Deployment or StatefulSet e.g. my-deployment, my-statefulset

0 commit comments

Comments
 (0)