]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
manager: remove ununsed containers
authorTomas Krizek <tomas.krizek@nic.cz>
Wed, 19 Jan 2022 16:04:09 +0000 (17:04 +0100)
committerAleš Mrázek <ales.mrazek@nic.cz>
Fri, 8 Apr 2022 14:17:53 +0000 (16:17 +0200)
manager/containers/README.md [deleted file]
manager/containers/debian-supervisord/Containerfile [deleted file]
manager/containers/debian/Containerfile [deleted file]
manager/containers/dev/Containerfile [deleted file]

diff --git a/manager/containers/README.md b/manager/containers/README.md
deleted file mode 100644 (file)
index 4d79935..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-# Container definition files
-
-All containers build configurations evolve from the `dev` container. If you want to change something, please do it mainly there. We consider **the `dev` container as a reference container**
-
-## Naming
-
-All containers defined here are named `knot-manager`. The directory name is the container's tag. So, for example - `knot-manager:dev` is the reference development container.
-
-## Building
-
-```sh
-for tag in 
-```
\ No newline at end of file
diff --git a/manager/containers/debian-supervisord/Containerfile b/manager/containers/debian-supervisord/Containerfile
deleted file mode 100644 (file)
index 9a4b5fe..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-FROM registry.nic.cz/knot/knot-resolver-manager/knot-manager:debian
-
-# Remove systemd
-# RUN apt-get remove -y systemd
-#
-# Well, we can't do that... The command above also uninstalls knot-resolver. Which
-# is kind of stupid. So let's just keep systemd installed and not start it.
-
-# install supervisord
-RUN python3 -m pip install supervisor
-
-# install tini init
-RUN apt-get update \
-  && apt-get install --no-install-recommends -y tini \
-  && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
-  && apt-get clean -y && rm -rf /var/lib/apt/lists/*
-
-# replace systemd with dummy init
-ENTRYPOINT ["/usr/bin/tini", "--"]
-CMD ["/bin/sleep", "inf"]
\ No newline at end of file
diff --git a/manager/containers/debian/Containerfile b/manager/containers/debian/Containerfile
deleted file mode 100644 (file)
index 9445f14..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-FROM docker.io/debian:latest
-
-ENV \
-  # build:
-  BUILD_ONLY_PACKAGES='wget' \
-  # python:
-  PYTHONFAULTHANDLER=1 \
-  PYTHONUNBUFFERED=1 \
-  PYTHONHASHSEED=random \
-  PYTHONDONTWRITEBYTECODE=1 \
-  # pip:
-  PIP_NO_CACHE_DIR=off \
-  PIP_DISABLE_PIP_VERSION_CHECK=on \
-  PIP_DEFAULT_TIMEOUT=100 \
-  # poetry:
-  POETRY_VERSION=1.1.5 \
-  POETRY_NO_INTERACTION=1 \
-  POETRY_VIRTUALENVS_CREATE=false \
-  POETRY_CACHE_DIR='/var/cache/pypoetry' \
-  PATH="$PATH:/root/.poetry/bin" \
-  NODE_VERSION=node_14.x
-ENV LC_ALL=C.UTF-8
-
-# System deps:
-RUN apt-get update \
-  && apt-get install --no-install-recommends -y \
-    bash \
-    build-essential git ca-certificates \
-    python3 python3-pip python3-dev python3-setuptools python3-wheel \
-    libcairo2-dev libgirepository1.0-dev \
-    gettext \
-    systemd \
-    curl \
-    dbus \
-    libcairo2-dev libgirepository1.0-dev \
-    # Defining build-time-only dependencies:
-    $BUILD_ONLY_PACKAGES \
-  # Install Knot Resolver
-  && wget https://secure.nic.cz/files/knot-resolver/knot-resolver-release.deb \
-  && dpkg -i knot-resolver-release.deb \
-  && rm knot-resolver-release.deb \
-  && apt-get update && apt-get install -y --no-install-recommends knot-resolver \
-  # Installing `poetry` package manager:
-  # https://github.com/python-poetry/poetry
-  && curl -sSL 'https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py' | python3 \
-  && poetry --version \
-  # Install test dependencies
-  && apt-get install --no-install-recommends procps curl \
-  && pip3 install requests requests-unixsocket \
-  # Removing build-time-only dependencies:
-  && apt-get remove -y $BUILD_ONLY_PACKAGES \
-  # Cleaning cache:
-  && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
-  && apt-get clean -y && rm -rf /var/lib/apt/lists/*
-
-# Create knot-resolver-manager systemd service
-COPY ./config/knot-resolver-manager.service /etc/systemd/system
-
-# Copy knot-resolver-manager YAML configuration file
-COPY ./config/kres-manager.yaml /etc/knot-resolver
-
-# Copy only requirements, to cache them in docker layer
-# no poetry.lock, because here we have a different python version
-COPY ./pyproject.toml /code/
-
-WORKDIR /code
-
-# Install project dependencies
-RUN poetry --version \
-  # Aghghgh! The packaged pip is buggy and just plainly fails installing dependencies
-  # so here we update it
-  && python3 -m pip --version \
-  && python3 -m pip install -U pip \
-  && python3 -m pip --version \
-  # and install the dependencies
-  && poetry install --no-dev --no-interaction --no-ansi
-
-# Here, we would copy the remaining code if we wanted to permanently keep it in the container. We don't do that, we use read-only bind mounts
-# COPY . /code
-
-CMD ["/bin/systemd"]
\ No newline at end of file
diff --git a/manager/containers/dev/Containerfile b/manager/containers/dev/Containerfile
deleted file mode 100644 (file)
index a5fc6e0..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-# source: https://github.com/wemake-services/wemake-django-template/blob/master/%7B%7Bcookiecutter.project_name%7D%7D/docker/django/Dockerfile
-
-# This Dockerfile uses multi-stage build to customize DEV and PROD images:
-# https://docs.docker.com/develop/develop-images/multistage-build/
-
-FROM docker.io/python:3.6.13-slim-buster
-
-# Agh, this would ideally be an ARG command, but podman has problems caching the build
-ENV KNOT_ENV=dev
-
-ENV \
-  # build:
-  BUILD_ONLY_PACKAGES='wget lsb-release gnupg' \
-  # python:
-  PYTHONFAULTHANDLER=1 \
-  PYTHONUNBUFFERED=1 \
-  PYTHONHASHSEED=random \
-  PYTHONDONTWRITEBYTECODE=1 \
-  # pip:
-  PIP_NO_CACHE_DIR=off \
-  PIP_DISABLE_PIP_VERSION_CHECK=on \
-  PIP_DEFAULT_TIMEOUT=100 \
-  # poetry:
-  POETRY_VERSION=1.1.5 \
-  POETRY_NO_INTERACTION=1 \
-  POETRY_VIRTUALENVS_CREATE=false \
-  POETRY_CACHE_DIR='/var/cache/pypoetry' \
-  PATH="$PATH:/root/.poetry/bin" \
-  NODE_VERSION=node_14.x
-
-
-# System deps:
-RUN apt-get update \
-  && apt-get install --no-install-recommends -y \
-    bash \
-    build-essential \
-    curl \
-    gettext \
-    git \
-    systemd \
-    dbus \
-    libcairo2-dev libgirepository1.0-dev \
-    # Defining build-time-only dependencies:
-    $BUILD_ONLY_PACKAGES \
-  # Install Knot Resolver
-  && wget https://secure.nic.cz/files/knot-resolver/knot-resolver-release.deb \
-  && dpkg -i knot-resolver-release.deb \
-  && rm knot-resolver-release.deb \
-  && apt-get update && apt-get install -y --no-install-recommends knot-resolver \
-  # Installing NodeJS
-  && curl -sSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - \
-  && echo "deb https://deb.nodesource.com/$NODE_VERSION $(lsb_release -s -c) main" | tee /etc/apt/sources.list.d/nodesource.list \
-  && echo "deb-src https://deb.nodesource.com/$NODE_VERSION $(lsb_release -s -c) main" | tee -a /etc/apt/sources.list.d/nodesource.list \
-  && apt-get update && apt-get install --no-install-recommends --no-install-suggests -y nodejs \
-  # Installing `poetry` package manager:
-  # https://github.com/python-poetry/poetry
-  && curl -sSL 'https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py' | python \
-  && poetry --version \
-  # Removing build-time-only dependencies:
-  && apt-get remove -y $BUILD_ONLY_PACKAGES \
-  # Cleaning cache:
-  && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
-  && apt-get clean -y && rm -rf /var/lib/apt/lists/*
-
-# Create knot-resolver-manager systemd service
-COPY ./config/knot-resolver-manager.service /etc/systemd/system
-
-# Copy knot-resolver-manager YAML configuration file
-COPY ./config/kres-manager.yaml /etc/knot-resolver
-
-# Copy only requirements, to cache them in docker layer
-COPY ./poetry.lock ./pyproject.toml ./package.json /code/
-
-WORKDIR /code
-
-# Install project dependencies
-RUN echo "Running in $KNOT_ENV" \
-  && poetry install \
-    $(if [ "$KNOT_ENV" != 'dev' ]; then echo '--no-dev'; fi) \
-    --no-interaction --no-ansi \
-  && if test "$KNOT_ENV" = "dev"; then \
-   npm install -g $(python -c "import json; print(*(k for k in json.loads(open('package.json').read())['dependencies']))"); fi
-
-# Here, we would copy the remaining code if we wanted to permanently keep it in the container. We don't do that, we use read-only bind mounts
-# COPY . /code
-
-CMD ["/bin/systemd"]
\ No newline at end of file