octodns / octodns-docker

OctoDNS – DNS as code – bundled as Docker images

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[feature] Adding curl (or something similar) to the image

alvarogonzalez-packlink opened this issue · comments

This image is very practical for CI processes, but is missing curl (or wget, or even nc) for making API calls after finishing, with the results of the execution.

Also, when using CircleCI orbs, lots of the installation scripts (for example, for GitHub CLI, or gcloud CLI...) use curl to pull the binaries. This make it less practical for running such jobs, as it's needed to install curl on every run of the job.

  • Does it make sense for you to add this tool to the base image?

I know it doesn't make sense to add every tool under the sun, but curl maybe helps people to bootstrap another tools or make basic curl calls easier.

It'd probably make sense to use these docker images as the base for a custom image with whatever tooling/scripts you need rather than to have them install things in case people want them, albeit fairly generic ones like curl. A simple Dockerfile like

FROM octodns/octodns:2023.07

RUN set -ex \
  && apt-get -y update \
  && apt-get -y install --no-install-recommends curl \
  && apt-get clean \
  && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

ENV PATH=/opt/octodns/env/bin:/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
CMD [ "/bin/sh" ]

Should do the trick.