b26fa1a2fbcfee7d03b0c8fd15ec3aa64ae70b9f |
|
10-Feb-2016 |
Daniel Mack <daniel@zonque.org> |
tree-wide: remove Emacs lines from all files
This should be handled fine now by .dir-locals.el, so need to carry that
stuff in every file. |
4afd3348c7506dd1d36305b7bcb9feb8952b9d6b |
|
27-Nov-2015 |
Lennart Poettering <lennart@poettering.net> |
tree-wide: expose "p"-suffix unref calls in public APIs to make gcc cleanup easy
GLIB has recently started to officially support the gcc cleanup
attribute in its public API, hence let's do the same for our APIs.
With this patch we'll define an xyz_unrefp() call for each public
xyz_unref() call, to make it easy to use inside a
__attribute__((cleanup())) expression. Then, all code is ported over to
make use of this.
The new calls are also documented in the man pages, with examples how to
use them (well, I only added docs where the _unref() call itself already
had docs, and the examples, only cover sd_bus_unrefp() and
sd_event_unrefp()).
This also renames sd_lldp_free() to sd_lldp_unref(), since that's how we
tend to call our destructors these days.
Note that this defines no public macro that wraps gcc's attribute and
makes it easier to use. While I think it's our duty in the library to
make our stuff easy to use, I figure it's not our duty to make gcc's own
features easy to use on its own. Most likely, client code which wants to
make use of this should define its own:
#define _cleanup_(function) __attribute__((cleanup(function)))
Or similar, to make the gcc feature easier to use.
Making this logic public has the benefit that we can remove three header
files whose only purpose was to define these functions internally.
See #2008. |
b5efdb8af40ea759a1ea584c1bc44ecc81dd00ce |
|
27-Oct-2015 |
Lennart Poettering <lennart@poettering.net> |
util-lib: split out allocation calls into alloc-util.[ch] |
f4f15635ec05293ffcc83a5b39f624bbabbd8fd0 |
|
27-Oct-2015 |
Lennart Poettering <lennart@poettering.net> |
util-lib: move a number of fs operations into fs-util.[ch] |
3ffd4af22052963e7a29431721ee204e634bea75 |
|
25-Oct-2015 |
Lennart Poettering <lennart@poettering.net> |
util-lib: split out fd-related operations into fd-util.[ch]
There are more than enough to deserve their own .c file, hence move them
over. |
07630cea1f3a845c09309f197ac7c4f11edd3b62 |
|
24-Oct-2015 |
Lennart Poettering <lennart@poettering.net> |
util-lib: split our string related calls from util.[ch] into its own file string-util.[ch]
There are more than enough calls doing string manipulations to deserve
its own files, hence do something about it.
This patch also sorts the #include blocks of all files that needed to be
updated, according to the sorting suggestions from CODING_STYLE. Since
pretty much every file needs our string manipulation functions this
effectively means that most files have sorted #include blocks now.
Also touches a few unrelated include files. |
3f6fd1ba65f962702753c4ad284b588e59689a23 |
|
29-Sep-2015 |
Lennart Poettering <lennart@poettering.net> |
util: introduce common version() implementation and use it everywhere
This also allows us to drop build.h from a ton of files, hence do so.
Since we touched the #includes of those files, let's order them properly
according to CODING_STYLE. |
25300b5a1fcf54674a69d0f4ab08925be00b0227 |
|
24-Aug-2015 |
Lennart Poettering <lennart@poettering.net> |
util: make machine_name_is_valid() a macro and move it to hostname-util.h
As it turns out machine_name_is_valid() does the exact same thing as
hostname_is_valid() these days, as it just invoked that and checked the
name length was < 64. However, hostname_is_valid() checks the length
against HOST_NAME_MAX anyway (which is 64 on Linux), hence any
additional check is redundant.
We hence replace machine_name_is_valid() by a macro that simply maps it
to hostname_is_valid() but sets the allow_trailing_dot parameter to
false. We also move this this call to hostname-util.h, to the same place
as the hostname_is_valid() declaration. |
72c0a2c255b172ebbb2a2b7dab7c9aec4c9582d9 |
|
15-Jun-2015 |
Lennart Poettering <lennart@poettering.net> |
everywhere: port everything to sigprocmask_many() and friends
This ports a lot of manual code over to sigprocmask_many() and friends.
Also, we now consistly check for sigprocmask() failures with
assert_se(), since the call cannot realistically fail unless there's a
programming error.
Also encloses a few sd_event_add_signal() calls with (void) when we
ignore the return values for it knowingly. |
ce30c8dcb41dfe9264f79f30c7f51c0e74576638 |
|
10-Jun-2015 |
Lennart Poettering <lennart@poettering.net> |
tree-wide: whenever we fork off a foreign child process reset signal mask/handlers
Also, when the child is potentially long-running make sure to set a
death signal.
Also, ignore the result of the reset operations explicitly by casting
them to (void). |
24882e06c135584f16f31ba8a00fecde8b7f6fad |
|
29-May-2015 |
Lennart Poettering <lennart@poettering.net> |
util: split out signal-util.[ch] from util.[ch]
No functional changes. |
587fec427c80b6c34dcf1d7570f891fcb652a7c5 |
|
09-Mar-2015 |
Lennart Poettering <lennart@poettering.net> |
importd: add API for exporting container/VM images
Also, expose it in machinectl. |
b6e676ce41508e2aeea22202fc8f234126177f52 |
|
05-Mar-2015 |
Lennart Poettering <lennart@poettering.net> |
importd: add new bus calls for importing local tar and raw images
This also adds "machinectl import-raw" and "machinectl import-tar" to
wrap these new bus calls.
THe commands basically do for local files that "machinectl pull-raw" and
friends do for remote files. |
7f444afa1b62920265fec99a61cb4dc53d521956 |
|
22-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: rename --verify=sum to --verify=checksum
This is how we call it internally, and also a bit more descriptive. |
3d7415f43f0fe6a821d7bc4a341ba371e8a30ef3 |
|
22-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: introduce new mini-daemon systemd-importd, and make machinectl a client to it
The old "systemd-import" binary is now an internal tool. We still use it
as asynchronous backend for systemd-importd. Since the import tool might
require some IO and CPU resources (due to qcow2 explosion, and
decompression), and because we might want to run it with more minimal
priviliges we still keep it around as the worker binary to execute as
child process of importd.
machinectl now has verbs for pulling down images, cancelling them and
listing them. |
ff2670ad11a1a29d483b7a246c95b159ddc1137c |
|
21-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: simplify dkr importer, by making use of generic import-job logic, used by the raw and tar importers
This gets us progress output as well xz/bzip2 support. |
8af3cf74df03f7528f9e2605ec7896a5daf0f711 |
|
21-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: support downloading bzip2-encoded images
This way, we can import CoreOS images unmodified. |
0100b6e1bf682385e0939d4dd7be815d5cdf0e1a |
|
21-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: also add verification support to tar importer |
5a3b1abd0ef47de9984d921463c2aaccc630fad6 |
|
21-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: improve logging |
c660bb094288d89762cdbedd08661127988e5548 |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: add a couple of additional suffixes to remove from raw images |
8f6950587ab7b4d6fe1b51241759cc3a4682b96d |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: make image verification optional |
85dbc41dc67ff49fd8a843dbac5b8b5cb0b61155 |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: add a simple scheme for validating the SHA256 sums of downloaded raw files |
0d6e763b48cabe8899a20823b015c9a988e38659 |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: port pull-raw to helper tools implemented for pull-tar
This allows us to reuse a lot more code, and simplify pull-raw
drastically. |
56ebfaf1ca185a93ffb372b6e1a1fa3a957d93cd |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: add support for pulling raw tar balls as containers
Ubuntu provides their cloud images optionally as tarball, hence also
support downloading those. |
a2e0337875addaf08225fbf9b231435ba12a88b5 |
|
20-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
util: make http url validity checks more generic, and move them to util.c |
edce2aed3aa93b84f7b4c70412bdb665da2977b0 |
|
16-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: support importing qcow2 images
With this change the import tool will now unpack qcow2 images into
normal raw disk images, suitable for usage with nspawn.
This allows has the benefit of also allowing importing Ubuntu Cloud
images for usage with nspawn. |
49bb233bb734536b9617d838f09a7bf9b8336003 |
|
16-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: support downloading .xz compressed images
That way we can download fedora cloud raw images as-is and decompress
them on-the-fly. |
5f129649b97bdff2bffefcd9c773157843ede6f6 |
|
15-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
nspawn,machined: change default container image location from /var/lib/container to /var/lib/machines
Given that this is also the place to store raw disk images which are
very much bootable with qemu/kvm it sounds like a misnomer to call the
directory "container". Hence, let's change this sooner rather than
later, and use the generic name, in particular since we otherwise try to
use the generic "machine" preferably over the more specific "container"
or "vm". |
aceac2f0b652dff701e5815c51c2e372e8fee84d |
|
15-Jan-2015 |
Lennart Poettering <lennart@poettering.net> |
import: rename "gpt" disk image type to "raw"
After all, nspawn can now dissect MBR partition levels, too, hence
".gpt" appears a misnomer. Moreover, the the .raw suffix for these files
is already pretty popular (the Fedora disk images use it for example),
hence sounds like an OK scheme to adopt. |
087682d103e08670963686d9b1bc1d35c412a63f |
|
26-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: make image root directory configurable, instead of hardcoding /var/lib/container |
8620a9a32391fd74d70ddc07c9b79729ad4ec067 |
|
26-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: beef up gpt importer to optionally make writable copy of read-only vendor image |
901992209e3c87a4cf06b530d7b26ae2d35680ef |
|
24-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: add a new "pull-gpt" verb for downloading GPT disk images from the internet |
0c7bf33a989a58922b3eb9aaa96abd773c8754c4 |
|
24-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: three minor fixes |
ea1ae8c38e669351b909cf8cc0c1e6fd140c1b58 |
|
24-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: make the dkr import URL a part of the import object, not the import name object |
91f4347ef7bde17418b365ed3a97a752fe65bd50 |
|
23-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: rename 'poll-dck' to 'pull-dkr'
I figure "pull-dck" is not a good name, given that one could certainly
read the verb in a way that might be funny for 16year-olds. ;-)
Also, don't hardcode the index URL to use, make it runtime and configure
time configurable instead. |
7eeeb28e45ae4d436bdccad1d519cfcb81c0762d |
|
19-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: Verb[] array can be static, too |
72648326ea6d3e68cdb0b5890df737047d031a41 |
|
19-Dec-2014 |
Lennart Poettering <lennart@poettering.net> |
import: add new minimal tool "systemd-import" for pulling down foreign containers and install them locally
This adds a simply but powerful tool for downloading container images
from the most popular container solution used today. Use it like
this:
# systemd-import pull-dck mattdm/fedora
# systemd-nspawn -M fedora
This will donwload the layers for "mattdm/fedora", and make them
available locally as /var/lib/container/fedora.
The tool is pretty complete, as long as it's only about pulling down
images, or updating them. Pushing or searching is not supported yet. |