kiwigrid / k8s-sidecar

This is a docker container intended to run inside a kubernetes cluster to collect config maps with a specified label and store the included files in a local folder.
MIT License
613 stars 183 forks source link

Cannot download binary files #250

Closed svolland-csgroup closed 1 year ago

svolland-csgroup commented 1 year ago

There are some issues that prevent downloading binary files, i.e. using binaryData config maps with *.url keys.

The issue can be reproduced with the following config map to download kubectl (just as an example)

apiVersion: v1
kind: ConfigMap
metadata:
  name: download-kubectl
  labels:
     download_binary: "1"
binaryData:
  # Download https://storage.googleapis.com/kubernetes-release/release/v1.26.0/bin/linux/amd64/kubectl
  kubectl.url: "aHR0cHM6Ly9zdG9yYWdlLmdvb2dsZWFwaXMuY29tL2t1YmVybmV0ZXMtcmVsZWFzZS9yZWxlYXNlL3YxLjI2LjAvYmluL2xpbnV4L2FtZDY0L2t1YmVjdGw="
jekkel commented 1 year ago

closed by #251