timescale / timescaledb-docker-ha

Create Docker images containing TimescaleDB, Patroni to be used by developers and Kubernetes.
Apache License 2.0
143 stars 38 forks source link

Bug Fix: Missing Barman Cloud entrypoints #459

Closed itay-grudev closed 1 month ago

itay-grudev commented 2 months ago

In #442 I added the python3-barman package in anticipation for the ImageCatalog feature in CloudNativePG that would allow running the official Timescale image in CNPG.

That PR though has two issues:

  1. Unlike python-pip, apt-get does not install package binaries, required for interaction with barman-cloud.
  2. It did not add necessary dependencies for Azure and Google cloud support.

I tried implementing it without python-pip, but the Azure Storage package python3-azure-storage is over 600MB which completely defeats the purpose of the size optimization. With pip the barman package only fetches azure-blob-storage and this results in around 300MB smaller image, compared to the deb package only approach.

I suspect that once I add python3-pip it may be beneficial for other as well to switch to pip packages instead of Debian packages as:

In fact if you request it, I will move the apt-get install -y python3-pip to the beginning of the Dockerfile so it is available to use earlier. I only kept it here so the Docker image is easier to build and use more cache.

P.S. Special thanks to @NiccoloFei for his assistance in debugging this.

itay-grudev commented 2 months ago

@graveland Can I trouble you with a review, again?

itay-grudev commented 1 month ago

@feikesteenbergen @graveland I would like to release support for TimescaleDB in the official CloudNativePG chart next week. We have everything else prepared, but this PR.

Would you be able to take allocate some time for a review?

itay-grudev commented 1 month ago

@graveland Would you like me to make that change now?

graveland commented 1 month ago

@graveland Would you like me to make that change now?

If you don't mind, thanks!

itay-grudev commented 1 month ago

@graveland I scanned through the Dockerfile and this seems as a good spot. I also explicitly added python3 so it's not marked as auto, as it is required at runtime.

itay-grudev commented 1 month ago

@graveland

P.S. I can't marge this, but ping me if you would like me to make any other changes.

graveland commented 1 month ago

All good, thanks!