Commit graph

8 commits

Author SHA1 Message Date
Christian Kellner
6e5b838892 pipeline: use API to setup stdio inside the container
Use the new the osbuild API to setup the standard input/output
inside the container, i.e. replace stdin, stdout, and stderr with
sockets provided by the host.
2019-10-30 18:44:55 +01:00
Lars Karlitski
cd59b94ded tree-wide: always explicitly pass check to subprocess.run
pylint recently started recommending this.
2019-09-24 20:17:04 +02:00
Tom Gundersen
3669978577 osbuild-run: remove any /etc/nsswitch.conf
On some hosts, systemd-tmpfiles will generate an nsswitch.conf
configuring DNS to be done via systemd-resolved, but this will
require the container to be booted and resolved to be running.

In other cases, a proper fall-back is configured, so this is not
a problem, but on some hosts this means DNS does not work.

Conversely, the default behavior with no nsswitch.conf at all
works just fine, always using nss-dns.

Let's simply delete the file if it is there, and rely on the
default.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2019-08-02 00:57:28 +02:00
Tom Gundersen
fd72ed80ba osbuild-run: generate SSL certificates also on Debian-based systems
Call update-ca-certificates if the binary is found, generating SSL
certificates in /etc in i similar way on Debian-based systems as
is being done on RedHat-based ones.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2019-07-31 01:34:31 +02:00
Tom Gundersen
d08aed8f12 osbuild-run: make update-ca-trust optional
This is a RHism, that is not available on Debian-based systems.
Do not make it a hard reqirement, as pipelines may be able to
function just fine without it.

In a follow-up commit we will also check for the Debian-based
equivalent.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2019-07-31 01:34:31 +02:00
Tom Gundersen
9fa827ab04 osbuild-run: refactor into functions
Prepare for follow-up patches adding more functionality.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2019-07-31 01:34:31 +02:00
Lars Karlitski
00f4e6ed8b osbuild-run: generate /etc/pki/tls/certs/ca-bundle.crt
There's no need to bind mount the full /etc/pki from the host. This file
can be generated from /usr.
2019-07-19 13:31:49 +02:00
Lars Karlitski
e6dd428107 osbuild.py: rename run-stage to osbuild-run
Run all programs in the build root through osbuild-run. The things it
sets up are probbaly needed by everything.
2019-06-14 18:45:55 +02:00