From da0e7eabb26e3b1eb845d4a2225160c888ce0cb9 Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Wed, 8 Jun 2022 00:26:40 +0200 Subject: [PATCH 1/4] Increase resources assigned to Vagrant environment Now, it gets 4 VCPUs and 4096 MB RAM. --- CHANGES.rst | 3 +++ Vagrantfile | 12 +++++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 640d901..7cb351a 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -6,6 +6,9 @@ Racker changelog in progress =========== +- Increase resources assigned to Vagrant environment. + Now, it gets 4 VCPUs and 4096 MB RAM. + 2022-05-20 0.2.0 ================ diff --git a/Vagrantfile b/Vagrantfile index 783f9b2..9e7500b 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -30,12 +30,18 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| # Configure host specifications machine.vm.provider :virtualbox do |v| - v.memory = 2048 - v.cpus = 2 + v.memory = 4096 + v.cpus = 4 v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"] - #v.customize ["modifyvm", :id, "--memory", 1024] v.customize ["modifyvm", :id, "--name", "rackerhost-debian11"] + #v.customize ["modifyvm", :id, "--memory", 4096] + + # Turn on nested virtualization. + v.customize ["modifyvm", :id, "--nested-hw-virt", "on"] + + # https://forums.virtualbox.org/viewtopic.php?f=1&t=59379 + v.customize ["modifyvm", :id, "--vtxux", "on"] end machine.vm.provision :shell, inline: <<-SHELL From 348fc4f9c2ff8eac4abb9f77e22b26f567651bd4 Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Wed, 8 Jun 2022 00:29:24 +0200 Subject: [PATCH 2/4] Improve platform guards and naming things --- CHANGES.rst | 1 + postroj/pkgprobe.py | 9 +++++++-- racker/cli.py | 3 --- testing/conftest.py | 4 ++-- testing/postroj/test_images.py | 5 +++++ testing/postroj/test_pkgprobe.py | 7 +++++++ testing/postroj/test_selftest.py | 8 ++++++++ testing/racker/test_run.py | 5 +++++ 8 files changed, 35 insertions(+), 7 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 7cb351a..907d84e 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -8,6 +8,7 @@ in progress - Increase resources assigned to Vagrant environment. Now, it gets 4 VCPUs and 4096 MB RAM. +- Improve platform guards and naming things 2022-05-20 0.2.0 diff --git a/postroj/pkgprobe.py b/postroj/pkgprobe.py index a794615..96a41bc 100644 --- a/postroj/pkgprobe.py +++ b/postroj/pkgprobe.py @@ -3,6 +3,7 @@ import io import logging import os +import sys from contextlib import redirect_stdout from functools import partial from typing import List @@ -31,6 +32,10 @@ def main(ctx, image: str, package: str, check_unit: List[str], check_network: Li Verify a distribution package """ + if sys.platform != "linux": + raise NotImplementedError(f"Unable to launch Linux systems on non-Linux machines yet, " + f"please use the Vagrant setup") + # Figure out the image from the list of available ones. dist = find_distribution(image) @@ -41,7 +46,7 @@ def main(ctx, image: str, package: str, check_unit: List[str], check_network: Li ip = ImageProvider(distribution=dist) rootfs = ip.image - # Adjust verbosity. + # TODO: Adjust verbosity. silent_boot = True ctx = noop if silent_boot: @@ -94,7 +99,7 @@ def install(self, package: str): # Install package. logger.info(f"Installing package {package}") if self.is_debian: - self.run(f"/usr/bin/apt install --yes {package}") + self.run(f"/usr/bin/apt-get install --yes {package}") elif self.is_redhat: self.run(f"/usr/bin/yum install -y {package}") elif self.is_suse: diff --git a/racker/cli.py b/racker/cli.py index c9622e2..5ae0c0d 100644 --- a/racker/cli.py +++ b/racker/cli.py @@ -11,8 +11,6 @@ from postroj.api import pull_curated_image from postroj.container import PostrojContainer from postroj.exceptions import ProvisioningError -from postroj.image import ImageProvider -from postroj.registry import find_distribution from postroj.util import boot, subprocess_get_error_message from racker.image import ImageLibrary @@ -131,7 +129,6 @@ def racker_run(ctx, interactive: bool, tty: bool, rm: bool, image: str, command: pc.wait() except subprocess.CalledProcessError as ex: - message = subprocess_get_error_message(exception=ex) logger.critical(f"Launching container failed. {message}") # subprocess_forward_stderr_stdout(exception=ex) diff --git a/testing/conftest.py b/testing/conftest.py index 86cd685..71388d3 100644 --- a/testing/conftest.py +++ b/testing/conftest.py @@ -74,13 +74,13 @@ def scmd_mock(): @pytest.fixture def scmd_first_command(scmd_mock): - def invoke(): + def invoker(): scmd_mock.assert_called_once() kwargs = scmd_mock.call_args[1] command = kwargs["command"] return command - return invoke + return invoker @pytest.fixture diff --git a/testing/postroj/test_images.py b/testing/postroj/test_images.py index 038fcb4..591e4a8 100644 --- a/testing/postroj/test_images.py +++ b/testing/postroj/test_images.py @@ -3,6 +3,7 @@ import json import logging import re +import sys from pathlib import Path, PosixPath from unittest import mock from unittest.mock import patch @@ -19,6 +20,10 @@ from testing.util import AnyStringWith +if sys.platform != "linux": + pytest.skip("Skipping Linux-only tests", allow_module_level=True) + + def test_list_images(): runner = CliRunner() diff --git a/testing/postroj/test_pkgprobe.py b/testing/postroj/test_pkgprobe.py index bf69205..91625df 100644 --- a/testing/postroj/test_pkgprobe.py +++ b/testing/postroj/test_pkgprobe.py @@ -1,10 +1,17 @@ # -*- coding: utf-8 -*- # (c) 2022 Andreas Motl +import sys + +import pytest from click.testing import CliRunner from postroj.cli import cli +if sys.platform != "linux": + pytest.skip("Skipping Linux-only tests", allow_module_level=True) + + def test_pkgprobe_webfs(delay): """ Spawn a Debian 9 "stretch" container, install a package from a 3rd party location, diff --git a/testing/postroj/test_selftest.py b/testing/postroj/test_selftest.py index 8920c96..daedfc2 100644 --- a/testing/postroj/test_selftest.py +++ b/testing/postroj/test_selftest.py @@ -1,9 +1,17 @@ # -*- coding: utf-8 -*- # (c) 2022 Andreas Motl +import sys + +import pytest + from postroj.registry import CuratedOperatingSystem from postroj.selftest import HostinfoProbe, get_selftest_distributions, selftest_multiple +if sys.platform != "linux": + pytest.skip("Skipping Linux-only tests", allow_module_level=True) + + def test_get_selftest_distributions(delay): result = get_selftest_distributions() assert len(result) > 10 diff --git a/testing/racker/test_run.py b/testing/racker/test_run.py index 91e9fd8..4edb12c 100644 --- a/testing/racker/test_run.py +++ b/testing/racker/test_run.py @@ -5,12 +5,17 @@ import sys from pathlib import Path +import pytest from click._compat import strip_ansi from click.testing import CliRunner from racker.cli import cli +if sys.platform != "linux": + pytest.skip("Skipping Linux-only tests", allow_module_level=True) + + def test_run_image_invalid(caplog): """ Spawning a container with an invalid image label should fail. From b3daa7f69a2e7e464fece16afd169bb60484fdc3 Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Wed, 8 Jun 2022 00:30:52 +0200 Subject: [PATCH 3/4] Improve central command invocation function --- CHANGES.rst | 1 + postroj/util.py | 30 +++++++++++++++++++++++++----- 2 files changed, 26 insertions(+), 5 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 907d84e..1f6fbc7 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -9,6 +9,7 @@ in progress - Increase resources assigned to Vagrant environment. Now, it gets 4 VCPUs and 4096 MB RAM. - Improve platform guards and naming things +- Improve central command invocation function 2022-05-20 0.2.0 diff --git a/postroj/util.py b/postroj/util.py index 68b128d..e4af0bb 100644 --- a/postroj/util.py +++ b/postroj/util.py @@ -43,15 +43,31 @@ def is_dir_empty(path: Path, missing_ok=False): return next(scan, None) is None -def cmd(command, check: bool = True, passthrough: bool = True, capture: bool = False, use_pty: bool = False): +def cmd(command, check: bool = True, passthrough: bool = None, capture: bool = False, use_stderr: bool = False, use_pty: bool = False, cwd: Union[Path, str] = None, **kwargs): """ Run command in a separate process. """ try: - if use_pty: - p = subprocess.run(shlex.split(command)) + command_encoded = shlex.split(command) + kwargs.update({ + "cwd": cwd, + }) + if use_stderr: + kwargs["stdout"] = sys.stderr + kwargs["stderr"] = sys.stderr + + if passthrough in [True, False] or capture and not use_pty: + logger.debug(f"Running with subprocess_tee: {command}") + p = subprocess_tee.run(command_encoded, tee=passthrough, **kwargs) else: - p = subprocess_tee.run(shlex.split(command), tee=passthrough) + logger.debug(f"Running with subprocess: {command} {kwargs}") + p = subprocess.run(command_encoded, **kwargs) + """ + if (not passthrough and not capture) or use_pty: + p = subprocess.run(command, **kwargs) + else: + p = subprocess_tee.run(command, tee=passthrough, **kwargs) + """ """ if capture: p = subprocess_tee.run(shlex.split(command), tee=passthrough) @@ -107,7 +123,9 @@ def fix_tty(): if not sys.stdin.isatty(): return - os.system("stty sane") + if sys.stdout.isatty(): + os.system("stty sane") + os.system("tput cnorm") # Clears the whole screen. # os.system("tput reset") @@ -158,6 +176,8 @@ def port_is_up(host: str, port: int): https://github.com/lovelysystems/lovely.testlayers/blob/0.7.0/src/lovely/testlayers/util.py#L6-L13 """ s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + # TODO: Make connect timeout configurable. + s.settimeout(5) ex = s.connect_ex((host, port)) if ex == 0: s.close() From d21208f5402b48e2b19fc46d348001bcbfeeafe3 Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Wed, 8 Jun 2022 00:31:15 +0200 Subject: [PATCH 4/4] Improve documentation --- CHANGES.rst | 1 + README.rst | 62 +++++++++++++++++++----------- doc/backlog.rst | 69 ++++++++++++++++------------------ doc/bugs.rst | 81 ++++++++++++++++++++++++++++++++++++++++ doc/comparison.rst | 4 +- doc/cratedb.rst | 69 ---------------------------------- doc/research/general.rst | 8 ++++ setup.py | 2 +- 8 files changed, 167 insertions(+), 129 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 1f6fbc7..5b28851 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -10,6 +10,7 @@ in progress Now, it gets 4 VCPUs and 4096 MB RAM. - Improve platform guards and naming things - Improve central command invocation function +- Improve documentation 2022-05-20 0.2.0 diff --git a/README.rst b/README.rst index 20b9445..6edfcfa 100644 --- a/README.rst +++ b/README.rst @@ -40,9 +40,9 @@ Racker :target: https://pypi.org/project/racker/ :alt: License -.. image:: https://img.shields.io/pypi/dm/racker.svg?label=PyPI%20downloads +.. image:: https://pepy.tech/badge/racker/month :target: https://pypi.org/project/racker/ - :alt: PyPI downloads + :alt: PyPI downloads / month ---- @@ -52,44 +52,61 @@ Racker About ***** -An experimental harness tool based on `systemd`_ and `systemd-nspawn`_, to run -`operating system containers `_, in the spirit of addressing some details of -`Docker Considered Harmful`_ and `Systemd vs. Docker`_. -At the same time, it is a tribute to the authors and contributors of GNU, Linux, -systemd, Python, VirtualBox, Vagrant, Docker, and more. +At a glance +=========== -Most people running Linux probably want to use `Podman`_ these days. For more -background, enjoy reading `Container wars`_ and `Container Tools Guide`_. +Racker is an experimental harness tool for provisioning and running operating +system containers. -Racker is ... -============= +For launching Linux operating systems, it is based on `systemd`_ and +`systemd-nspawn`_, to run `operating system containers `_, +in the spirit of addressing some details of `Docker Considered Harmful`_ and +`Systemd vs. Docker`_. -- A runtime harness for testing software packages and similar purposes, in + +Details +======= + +With Racker, you can ... + +- Launch an interactive command prompt within a Linux environment or invoke + programs non-interactively. + +- Use the runtime harness for testing software packages and similar purposes, in different environments, mostly run headless and non-interactively. +Racker is ... + - A lightweight wrapper around ``systemd-nspawn`` to provide and launch container environments for/with ``systemd``. - A lightweight wrapper around ``vagrant`` to provide convenient access to all things needing a full VM, like running Windows on Linux or macOS. +- A tribute to the authors and contributors of GNU, Linux, systemd, Python, + VirtualBox, Vagrant, Docker, Windows, Windows Docker Machine and countless + others. + Comparison with similar tools ============================= -The aims of Racker are very similar to `Distrobox`_ and `Toolbox`_. However, -there are also some differences. +The aims of Racker are very similar to `Docker`_, `Podman`_, `Distrobox`_ and +`Toolbox`_. However, there are also some differences. -- Racker is currently based on `systemd-nspawn`_ instead of `Docker`_ or - `Podman`_. -- Racker can invoke any kind of container payload, but strongly focuses on - running `OS containers`_ aka. `OS-level virtualization`_, using `systemd`_ - as init process. -- Racker aims to provide concise usability by folding its usage into a single - command. +Most people running Linux probably want to use `Podman`_ these days. For more +background, enjoy reading `Container wars`_ and `Container Tools Guide`_. + +- Racker is currently based on `systemd-nspawn`_ and `Vagrant`_ instead of + `Docker`_ or `Podman`_. +- Racker's focus is to provide easy provisioning and launching `OS containers`_ + aka. `OS-level virtualization`_, using `systemd`_ as init process. - The acquisition and provisioning of operating system images does not need any special preparation steps, those are handled by Racker on the fly. +- Racker aims to provide concise usability by folding its usage into a single + command. +- Racker is written in Python instead of Golang or Bash. See also `Comparison with similar tools - more details`_. @@ -398,6 +415,7 @@ Troubleshooting .. _autopkgtest: https://www.freedesktop.org/wiki/Software/systemd/autopkgtest/ .. _Changing Roots: http://0pointer.de/blog/projects/changing-roots.html +.. _Chocolatey: https://chocolatey.org/ .. _Comparison with similar tools - more details: https://github.com/cicerops/racker/blob/main/doc/comparison.rst .. _Container Tools Guide: https://github.com/containers/buildah/tree/main/docs/containertools .. _Container wars: https://github.com/cicerops/racker/blob/main/doc/research/container-wars.rst @@ -421,6 +439,8 @@ Troubleshooting .. _Systemd vs. Docker: https://lwn.net/Articles/676831/ .. _Toolbox: https://containertoolbx.org/ .. _umoci: https://github.com/opencontainers/umoci +.. _Vagrant: https://www.vagrantup.com/ +.. _Windows Docker Machine: https://github.com/StefanScherer/windows-docker-machine .. _Containers without a Container Manager, with systemd: https://invidious.fdn.fr/watch?v=sqhojVPr7xM .. _Lennart Poettering und Kay Sievers über Systemd: https://invidious.fdn.fr/watch?v=6Q_iTG6_EF4 diff --git a/doc/backlog.rst b/doc/backlog.rst index 8f92941..83eada6 100644 --- a/doc/backlog.rst +++ b/doc/backlog.rst @@ -7,48 +7,47 @@ Racker backlog Those are just random notes about ideas and more. -*********** -Iteration 2 -*********** - -- [x] Check if software tests can be invoked on CI/GHA. -- [x] Improve software tests. -- [x] Split functionality between ``racker`` and ``postroj``. - - - ``racker {run,ps,pull,logs}`` - - ``postroj {list-images,pkgprobe,selftest}`` - - ``pronto opensuse/tumbleweed hostnamectl`` (``pronto.hexagon`` (hx), ``pronto.kaxon`` (kx)) - -- [x] Continue renaming to ``racker``. -- [x] Improve error messages, see "Compatibility" section - Compare with ``docker run --rm -it debian:bullseye-slim foo``. - - - ``racker run -it --rm debian-stretch hostnamectl`` - - ``racker run -it --rm debian-stretch /bin/hostnamectl`` - - ``racker run -it --rm debian-stretch /usr/bin/hostnamectl`` - -- [x] Provide more advanced and generic image (label) resolution. - From docker.io, ghcr.io, registry.access.redhat.com, etc. -- [x] Improve documentation -- [x] Is it possible to run RHEL and SLES? - - - registry.access.redhat.com/rhel7/rhel - - registry.suse.com/bci/bci-base - - https://registry.suse.com/ - - *********** Iteration 3 *********** +- [o] Support for Windows. ``windows/nanoserver:1809`` and ``windows/servercore:ltsc2019``. +- [o] Support for Windows 11 and Windows Server 2022 + + - https://github.com/StefanScherer/packer-windows + - https://app.vagrantup.com/StefanScherer/boxes/windows_2022 + - ``mcr.microsoft.com/windows/servercore:ltsc2022-amd64`` +- [o] Provide curated image types per ``os://`` or ``vagrant://``. - [o] Tests: Wait for container to properly shut down before moving on. - Q: When running ``postroj selftest``, why is there more output from containers shutting down, while the program is finished already? - Q: Why are the tests failing when trying to subsequently spin up / tear down the same container? +- [o] Use/integrate with ``mkosi``. + + - https://github.com/systemd/mkosi + - http://0pointer.net/blog/mkosi-a-tool-for-generating-os-images.html + - https://lwn.net/Articles/726655/ + - https://github.com/asiffer/netspot/search?q=mkosi + + +************* +Iteration 3.5 +************* + +- [o] Windows support leftovers + + - --cpus=8 --memory=8192M + - https://github.com/docker/machine/issues/531#issuecomment-73938730 + - --mount type=git,src=https://github.com/crate/crate,dst=C:/src + - --repository=https://github.com/crate/crate + - https://github.com/StefanScherer/packer-windows + - Make piping from STDIN possible + - Display machine resources (VCPUs, memory) before starting the command/job. - [o] Address issues in ``bugs.rst`` +- [o] When using ``apt-get``, use ``DEBIAN_FRONTEND=noninteractive`` - [o] Invoke arbitrary Docker containers, even when they don't contain an OS root directory. @@ -56,13 +55,6 @@ Iteration 3 - Directory ``/var/lib/postroj/archive/hello-world.img/rootfs`` doesn't look like it has an OS root directory. Refusing. - ``unshare --fork --pid --mount-proc --root=/var/lib/postroj/images/hello-world ./hello`` -- [o] Use/integrate with ``mkosi``. - - - https://github.com/systemd/mkosi - - http://0pointer.net/blog/mkosi-a-tool-for-generating-os-images.html - - https://lwn.net/Articles/726655/ - - https://github.com/asiffer/netspot/search?q=mkosi - - [o] Improve timeout behaviors across the board, using ``with stopit.ThreadingTimeout(timeout) as to_ctx_mgr``. - [o] Tests: ``racker pull foo``. Also remove ``/var/lib/postroj/archive/foo`` again. @@ -71,6 +63,9 @@ Iteration 3 - [o] ``racker --verbose run -it --rm https://cloud-images.ubuntu.com/minimal/daily/focal/current/focal-minimal-cloudimg-amd64-root.tar.xz /bin/bash`` - [o] TODO: Introduce appropriate exception classes. - [o] Maybe use ``ubi8/ubi-init`` instead of ``ubi8/ubi``? +- [o] How to integrate with other tools from https://github.com/topics/systemd-nspawn +- [o] https://github.com/NixOS/nixops + *********** diff --git a/doc/bugs.rst b/doc/bugs.rst index e7afb68..9804b09 100644 --- a/doc/bugs.rst +++ b/doc/bugs.rst @@ -26,3 +26,84 @@ See:: stdout/stderr redirection ========================= Most probably, since c5266940/a721345, the progress bar of ``skopeo`` isn't displayed anymore. + + +VirtualBox on macOS with nested virtualization +============================================== +:: + + ==> 2019-box: Booting VM... + There was an error while executing `VBoxManage`, a CLI used by Vagrant + for controlling VirtualBox. The command and stderr is shown below. + + Command: ["startvm", "5f422042-d72f-46c5-9bcf-ec27eeee2e06", "--type", "headless"] + + Stderr: VBoxManage: error: Cannot enable nested VT-x/AMD-V without nested-paging and unrestricted guest execution! + VBoxManage: error: (VERR_CPUM_INVALID_HWVIRT_CONFIG) + VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole + 2022-06-07 15:58:59,573 [racker.cli ] CRITICAL: Launching container failed. Command 'vagrant up --provider=virtualbox 2019-box' returned non-zero exit status 1. + + + +Using the CrateDB RPM package on openSUSE +========================================= + +| A: Workaround applied by running ``rpm --install --nodeps``. +| TODO: Maybe adjust the RPM dependencies? + +:: + + zypper --non-interactive install crate-4.7.2-1.x86_64.rpm + Loading repository data... + Reading installed packages... + Resolving package dependencies... + + Problem: nothing provides 'systemd-units' needed by the to be installed crate-4.7.2-1.x86_64 + Solution 1: do not install crate-4.7.2-1.x86_64 + Solution 2: break crate-4.7.2-1.x86_64 by ignoring some of its dependencies + + Choose from above solutions by number or cancel [1/2/c/d/?] (c): c + +:: + + rpm -i crate-4.7.2-1.x86_64.rpm + warning: crate-4.7.2-1.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID 06f6eaeb: NOKEY + error: Failed dependencies: + shadow-utils is needed by crate-4.7.2-1.x86_64 + systemd-units is needed by crate-4.7.2-1.x86_64 + + +Spawning a container from the CrateDB Docker image +================================================== + +Currently, as of 2022-06, the CrateDB Docker image is based on CentOS 7, which +has a systemd installation that is too old for being able to invoke nested +systemd environments. + +:: + + racker run -it --rm crate/crate:nightly bash + +:: + + Failed to start transient service unit: Cannot set property AddRef, or unknown property. + +=> systemd too old. + + +Docker context on Windows VM not reachable +========================================== + +https://github.com/docker/machine/issues/531 + +:: + + $ docker --context=2019-box ps + error during connect: Get "https://192.168.59.90:2376/v1.24/containers/json": x509: certificate is valid for 169.254.232.221, 172.30.112.1, 10.0.2.15, 127.0.0.1, not 192.168.59.90 + + $ docker --context=2019-box ps + error during connect: Get "https://192.168.59.90:2376/v1.24/containers/json": x509: certificate signed by unknown authority (possibly because of "crypto/rsa: verification error" while trying to verify candidate authority certificate "Docker TLS Root") + +Solution:: + + docker context rm 2019-box diff --git a/doc/comparison.rst b/doc/comparison.rst index cf344f2..0fc3902 100644 --- a/doc/comparison.rst +++ b/doc/comparison.rst @@ -63,7 +63,8 @@ invoking `systemd-nspawn`_ without using the ``--boot`` option. Notes ***** -There is also `Boombox`_, `CoreOS toolbox`_, `microos-toolbox`_ and `tlbx`_. +There is also `Boombox`_, `CoreOS toolbox`_, `docker-coreos-toolbox-ubuntu`_, +`microos-toolbox`_ and `tlbx`_. .. _Boombox: https://github.com/anthr76/boombox @@ -72,6 +73,7 @@ There is also `Boombox`_, `CoreOS toolbox`_, `microos-toolbox`_ and `tlbx`_. .. _Distrobox: https://github.com/89luca89/distrobox .. _Distrobox - Containers distribution support: https://distrobox.privatedns.org/compatibility.html#containers-distros .. _distrobox-init: https://distrobox.privatedns.org/usage/distrobox-init.html +.. _docker-coreos-toolbox-ubuntu: https://github.com/wallneradam/docker-coreos-toolbox-ubuntu .. _microos-toolbox: https://github.com/openSUSE/microos-toolbox .. _systemd-nspawn: https://www.freedesktop.org/software/systemd/man/systemd-nspawn.html .. _tlbx: https://gitlab.com/uppercat/tlbx diff --git a/doc/cratedb.rst b/doc/cratedb.rst index 61c9df0..45fc533 100644 --- a/doc/cratedb.rst +++ b/doc/cratedb.rst @@ -40,72 +40,3 @@ Test package on Fedora 36:: HTTP/1.1 503 Service Unavailable Improve! - - -************** -postroj invoke -************** - -Purpose: Invoke programs within a Windows/Java/OpenJDK environment. - -:: - - # Basic usage. - postroj invoke \ - --system=windows-1809 --cpus=8 --memory=8192M \ - --mount type=git,src=https://github.com/crate/crate,dst=C:/src \ - -- \ - cmd /C "cd src && gradlew :server:test -Dtests.crate.run-windows-incompatible=false" - - # Advanced usage. - postroj invoke \ - --environment=windows-1809 --cpus=8 --memory=8192M \ - --repository=https://github.com/crate/crate \ - --command="gradlew :server:test -Dtests.crate.run-windows-incompatible=false" - - -******** -Failures -******** - - -Using the CrateDB RPM package on openSUSE -========================================= - -| A: Workaround applied by running ``rpm --install --nodeps``. -| TODO: Maybe adjust the RPM dependencies? - -:: - - zypper --non-interactive install crate-4.7.2-1.x86_64.rpm - Loading repository data... - Reading installed packages... - Resolving package dependencies... - - Problem: nothing provides 'systemd-units' needed by the to be installed crate-4.7.2-1.x86_64 - Solution 1: do not install crate-4.7.2-1.x86_64 - Solution 2: break crate-4.7.2-1.x86_64 by ignoring some of its dependencies - - Choose from above solutions by number or cancel [1/2/c/d/?] (c): c - -:: - - rpm -i crate-4.7.2-1.x86_64.rpm - warning: crate-4.7.2-1.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID 06f6eaeb: NOKEY - error: Failed dependencies: - shadow-utils is needed by crate-4.7.2-1.x86_64 - systemd-units is needed by crate-4.7.2-1.x86_64 - - -Spawning a container from the CrateDB Docker image -================================================== - -:: - - racker run -it --rm crate/crate:nightly bash - -:: - - Failed to start transient service unit: Cannot set property AddRef, or unknown property. - -=> systemd too old. diff --git a/doc/research/general.rst b/doc/research/general.rst index 79d598a..7aa71e6 100644 --- a/doc/research/general.rst +++ b/doc/research/general.rst @@ -165,3 +165,11 @@ Unikernels - https://www.inovex.de/de/blog/containers-docker-containerd-nabla-kata-firecracker/ - https://mirage.io/docs/hello-world + + +Kubernetes +========== + +- https://blog.tilt.dev/2021/03/18/kubernetes-is-so-simple.html +- https://github.com/kubernetes-sigs/kind +- https://www.docker.com/blog/welcome-tilt-fixing-the-pains-of-microservice-development-for-kubernetes/ diff --git a/setup.py b/setup.py index 994ad89..b6c8b13 100644 --- a/setup.py +++ b/setup.py @@ -12,7 +12,7 @@ author="Andreas Motl", author_email="andreas.motl@cicerops.de", url="https://github.com/cicerops/racker", - description="An experimental harness tool based on systemd-nspawn containers", + description="Racker is an experimental harness tool for provisioning and running operating system containers", long_description=README, download_url="https://pypi.org/project/racker/", packages=["racker", "postroj"],