From 3480255db4ae291db7d54d88ec676615cb92d5ef Mon Sep 17 00:00:00 2001 From: ajanikow <12255597+ajanikow@users.noreply.github.com> Date: Thu, 1 Jul 2021 21:59:50 +0000 Subject: [PATCH 1/2] Deprecate Alpine Image usage --- main.go | 2 +- pkg/operator/operator.go | 1 - pkg/util/k8sutil/pods.go | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/main.go b/main.go index ae4bf6cdd..e9dc38d74 100644 --- a/main.go +++ b/main.go @@ -145,6 +145,7 @@ func init() { f.BoolVar(&operatorOptions.enableStorage, "operator.storage", false, "Enable to run the ArangoLocalStorage operator") f.BoolVar(&operatorOptions.enableBackup, "operator.backup", false, "Enable to run the ArangoBackup operator") f.StringVar(&operatorOptions.alpineImage, "operator.alpine-image", UBIImageEnv.GetOrDefault(defaultAlpineImage), "Docker image used for alpine containers") + f.MarkDeprecated("operator.alpine-image", "Value is not used anymore") f.StringVar(&operatorOptions.metricsExporterImage, "operator.metrics-exporter-image", MetricsExporterImageEnv.GetOrDefault(defaultMetricsExporterImage), "Docker image used for metrics containers by default") f.StringVar(&operatorOptions.arangoImage, "operator.arango-image", ArangoImageEnv.GetOrDefault(defaultArangoImage), "Docker image used for arango by default") f.BoolVar(&chaosOptions.allowed, "chaos.allowed", false, "Set to allow chaos in deployments. Only activated when allowed and enabled in deployment") @@ -328,7 +329,6 @@ func newOperatorConfigAndDeps(id, namespace, name string) (operator.Config, oper EnableStorage: operatorOptions.enableStorage, EnableBackup: operatorOptions.enableBackup, AllowChaos: chaosOptions.allowed, - AlpineImage: operatorOptions.alpineImage, MetricsExporterImage: operatorOptions.metricsExporterImage, ArangoImage: operatorOptions.arangoImage, SingleMode: operatorOptions.singleMode, diff --git a/pkg/operator/operator.go b/pkg/operator/operator.go index f02621f94..7e9331454 100644 --- a/pkg/operator/operator.go +++ b/pkg/operator/operator.go @@ -88,7 +88,6 @@ type Config struct { PodName string ServiceAccount string LifecycleImage string - AlpineImage string ArangoImage string MetricsExporterImage string EnableDeployment bool diff --git a/pkg/util/k8sutil/pods.go b/pkg/util/k8sutil/pods.go index 49a1cd366..82eb0d45e 100644 --- a/pkg/util/k8sutil/pods.go +++ b/pkg/util/k8sutil/pods.go @@ -274,7 +274,7 @@ func RocksdbEncryptionReadOnlyVolumeMount() core.VolumeMount { func ArangodInitContainer(name, id, engine, executable, operatorImage string, requireUUID bool, securityContext *core.SecurityContext) core.Container { uuidFile := filepath.Join(ArangodVolumeMountDir, "UUID") engineFile := filepath.Join(ArangodVolumeMountDir, "ENGINE") - var command []string = []string{ + var command = []string{ executable, "uuid", "--uuid-path", From 365e27a597a29acfdd94f1827fcf122b0fc6752f Mon Sep 17 00:00:00 2001 From: ajanikow <12255597+ajanikow@users.noreply.github.com> Date: Thu, 1 Jul 2021 22:01:07 +0000 Subject: [PATCH 2/2] CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e1cdecad9..14596c6a6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # Change Log ## [master](https://github.com/arangodb/kube-arangodb/tree/master) (N/A) +- Deprecate Alpine image usage - Use persistent name and namespace in ArangoDeployment reconcilation loop ## [1.1.9](https://github.com/arangodb/kube-arangodb/tree/1.1.9) (2021-05-28)