Skip to content

Commit

Permalink
Merge pull request #64 from cybozu-go/envfrom
Browse files Browse the repository at this point in the history
use Env instead of EnvFrom for export data upload Job
  • Loading branch information
satoru-takeuchi authored Nov 15, 2024
2 parents a6f15d6 + 3b135c3 commit a83bcdc
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions internal/controller/mantlebackup_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -1287,12 +1287,25 @@ func (r *MantleBackupReconciler) createOrUpdateExportDataUploadJob(ctx context.C
Name: "OBJECT_STORAGE_ENDPOINT",
Value: r.objectStorageSettings.Endpoint,
},
},
EnvFrom: []corev1.EnvFromSource{
{
SecretRef: &corev1.SecretEnvSource{
LocalObjectReference: corev1.LocalObjectReference{
Name: r.envSecret,
Name: "AWS_ACCESS_KEY_ID",
ValueFrom: &corev1.EnvVarSource{
SecretKeyRef: &corev1.SecretKeySelector{
LocalObjectReference: corev1.LocalObjectReference{
Name: r.envSecret,
},
Key: "AWS_ACCESS_KEY_ID",
},
},
},
{
Name: "AWS_SECRET_ACCESS_KEY",
ValueFrom: &corev1.EnvVarSource{
SecretKeyRef: &corev1.SecretKeySelector{
LocalObjectReference: corev1.LocalObjectReference{
Name: r.envSecret,
},
Key: "AWS_SECRET_ACCESS_KEY",
},
},
},
Expand Down

0 comments on commit a83bcdc

Please sign in to comment.