summaryrefslogtreecommitdiffstats
path: root/src/machine (follow)
Commit message (Collapse)AuthorAgeFilesLines
* introduce report_errno_and_exit() helper (#35028)Luca Boccassi2024-11-062-17/+0
|\ | | | | | | | | This is a follow for https://github.com/systemd/systemd/pull/34853. In particular, this comment https://github.com/systemd/systemd/pull/34853#discussion_r1825837705.
| * process-util: introduce report_errno_and_exit() as part of ↵Ivan Kruglov2024-11-062-17/+0
| | | | | | | | src/basic/process-util.{h,c}
* | machine: introduce io.systemd.Machine.Open methodIvan Kruglov2024-11-063-0/+197
| |
* | machine: machine_default_shell_path() & machine_default_shell_args() helper ↵Ivan Kruglov2024-11-063-17/+34
| | | | | | | | functions
* | machine: introduce machine_start_getty() and machine_start_shell() helpersIvan Kruglov2024-11-063-209/+248
|/
* machine: use ImageUpdateParameters in io.systemd.MachineImage.UpdateIvan Kruglov2024-11-011-17/+9
|
* machine: introduce io.systemd.MachineImage.Remove methodIvan Kruglov2024-11-013-1/+70
|
* machine: introduce io.systemd.MachineImage.Clone methodIvan Kruglov2024-11-013-1/+88
|
* machine: use report_errno_and_exit() in dbus codeIvan Kruglov2024-11-011-14/+2
|
* machine: introduce report_errno_and_exit()Ivan Kruglov2024-11-012-0/+17
|
* machine: align polkit verb of io.systemd.MachineImage.Update with the rest ↵Ivan Kruglov2024-11-011-1/+1
| | | | of the code
* util-lib/systemd-run: implement race-free PTY peer opening (#34953)Luca Boccassi2024-11-011-5/+8
|\ | | | | | | | | | | | | | | This makes use of the new TIOCGPTPEER pty ioctl() for directly opening a PTY peer, without going via path names. This is nice because it closes a race around allocating and opening the peer. And also has the nice benefit that if we acquired an fd originating from some other namespace/container, we can directly derive the peer fd from it, without having to reenter the namespace again.
| * machined: port to pty_open_peer_racefree()Lennart Poettering2024-10-301-5/+8
| |
* | machine: lookup_machine_by_name_or_pidref() returns negative errno on failureYu Watanabe2024-10-312-5/+3
| | | | | | | | | | | | | | | | This effectively reverts d2c1451b7398f13439b694450a23def3cf31c8db. After the commit d2ebf5cc1d59e29139f06efaa3a9b2c184cdaa25, sd_varlink_error() returns negative errno, hence the function always return negative errno on failure.
* | machine: use JSON_BUILD_PAIR_STRV_ENV_PAIR_NON_EMPTY()Yu Watanabe2024-10-311-4/+4
| | | | | | | | Also use JSON_BUILD_PAIR_UNSIGNED_NOT_EQUAL().
* | machined: ACQUIRE_METADATA_NO is zeroYu Watanabe2024-10-311-2/+1
| | | | | | | | | | Follow-ups for a94fbcaa35dc63f32fbf86d25f63f6ac40a0d8b0 and 9de215219c8783e3239af27baf62275730ab51a8.
* | machine: use sd_json_variant_append_arraybo() and ↵Yu Watanabe2024-10-311-24/+17
|/ | | | | | JSON_BUILD_PAIR_VARIANT_NON_NULL() Follow-up for 45755275e5ae747bf79e6c7bdd9a055711ebc71f.
* machine: operation should not send a response when 'done' callback setIvan Kruglov2024-10-251-14/+17
|
* machine: use AcquireMetadata in io.systemd.MachineImage.List methodIvan Kruglov2024-10-211-8/+10
|
* machine: add Addresses field in varlink io.systemd.Machine.List outputIvan Kruglov2024-10-211-1/+46
| | | | This is equivalent to DBus implementation of GetMachineAddresses.
* machine: add OSRelease and UIDShift fields in varlink ↵Ivan Kruglov2024-10-211-6/+36
| | | | | | | | io.systemd.Machine.List output This commit adds support of the above mentioned fields. This is equivalent to DBus implementation of: - GetMachineOSRelease - GetMachineUIDShift
* machine: enum AcquireMetadataIvan Kruglov2024-10-213-0/+24
|
* machine: rework Operation logic to reuse in varlink interfaceIvan Kruglov2024-10-215-43/+68
|
* machine: fix typoYu Watanabe2024-10-161-1/+1
| | | | Follow-up for ad0d4f9a4c340f3fd5f0fcf646f7c762722737cd.
* machine: add MachineImage interfaceYu Watanabe2024-10-151-2/+6
| | | | | Follow-up for fb0ea6a6a36b5fa97e6c57d608bb9f7acb63c8b2. Fixes #34772.
* Merge pull request #34723 from poettering/machined-pidref-moreLennart Poettering2024-10-153-42/+60
|\ | | | | machined: switch remaining Varlink overs over to use json_dispatch_pidref() and friends
| * machined: port all varlink APIs over to new PidRef serializationLennart Poettering2024-10-143-42/+60
| |
* | machine: trivial coding style cleanupsYu Watanabe2024-10-151-8/+4
| |
* | machine: fix memleak in vl_method_list_images()Yu Watanabe2024-10-151-2/+4
| | | | | | | | Fixes an issue in fb0ea6a6a36b5fa97e6c57d608bb9f7acb63c8b2.
* | machine: lookup_machine_by_name_or_pid() may return 1 on error and it is ↵Yu Watanabe2024-10-152-3/+5
| | | | | | | | | | | | | | | | | | already replied Follow-ups for 1bd979dddbb6ed3ffe410d78a7ff80cbb1c42a64 and later commits. Fixes #34764.
* | machine: listen on io.systemd.MachineImage socketIvan Kruglov2024-10-141-1/+5
| |
* | machine: introduce io.systemd.MachineImage.Update varlink methodIvan Kruglov2024-10-144-1/+98
| | | | | | | | | | | | | | | | io.systemd.MachineImage.Update implements the following dbus org.freedesktop.machine1.Manager interfaces: - RenameImage - MarkImageReadOnly - SetImageLimit
* | machine: introduce io.systemd.MachineImage.List varlink methodIvan Kruglov2024-10-141-6/+121
| | | | | | | | | | | | | | | | | | | | | | io.systemd.MachineImage.List implements the following dbus org.freedesktop.machine1.Manager interfaces: - GetImage - ListImages - GetImageHostname - GetImageMachineID - GetImageMachineInfo - GetImageOSRelease
* | machine: generalize rename_image_and_update_cache() logicIvan Kruglov2024-10-143-11/+30
| | | | | | | | This is a prep step to reuse the function in varlink interface
* | machine: move manager_acquire_image to src/machine/machined-core.cIvan Kruglov2024-10-144-55/+55
|/ | | | This is a prep step to reuse the function in varlink interface.
* Merge pull request #34703 from poettering/pidref-varlinkLennart Poettering2024-10-112-15/+6
|\ | | | | Serialize "PidRef" in a reasonable way in Varlink interfaces
| * machined: also take new ProcessId structure when registering processesLennart Poettering2024-10-111-14/+5
| |
| * machined: make List() varlink method return a full pidref JSON object for leaderLennart Poettering2024-10-111-1/+1
| | | | | | | | | | This new call has not been released yet, hence we can still change the encoding of the "leader" field.
* | machine: use sd_json_dispatch_pid() in varlink codeIvan Kruglov2024-10-103-9/+10
| |
* | machine: switch to use PidRef when lookup machine by pid in dbus and varlink ↵Ivan Kruglov2024-10-105-20/+21
| | | | | | | | | | | | | | interfaces This commit includes adding introduce manager_get_machine_by_pidref() as a replacement for manager_get_machine_by_pid() and moving surrounding code to utilise PidRef.
* | machine: use sd_json_dispatch_signal() in varlink codeIvan Kruglov2024-10-101-4/+1
| |
* | machine: remove redundant else if lookup_machine_by_name_or_pid()Ivan Kruglov2024-10-101-1/+1
|/
* machined: use sd_json_dispatch_uint() when parsing CIDLennart Poettering2024-10-101-15/+15
| | | | | This is preferable, because we will accept CIDs encoded as strings too now, as we do for all other integers. Also, it's shorter. Yay!
* Merge pull request #34679 from DaanDeMeyer/bus-logDaan De Meyer2024-10-091-1/+1
|\ | | | | Various logging improvements
| * bus-util: Log more information when connecting to a bus socket failsDaan De Meyer2024-10-091-1/+1
| | | | | | | | | | Let's log about which bus we're trying to connect to and what transport we're using to do it.
* | machine: extend io.systemd.Machine.List output with sshPrivateKeyPath fieldIvan Kruglov2024-10-071-1/+2
| | | | | | | | Effectivelly, this is an implementation of GetMachineSSHInfo in dbus.
* | machine: use JSON_BUILD_PAIR_STRING_NON_EMPTY() in io.systemd.Machine.List ↵Ivan Kruglov2024-10-071-4/+4
| | | | | | | | output
* | machine: introduce io.systemd.Machine.Kill varlink methodIvan Kruglov2024-10-073-1/+67
| |
* | machine: introduce io.systemd.Machine.Terminate varlink methodIvan Kruglov2024-10-073-1/+29
| |
* | machine: introduce io.systemd.Machine.Unregister varlink methodIvan Kruglov2024-10-073-2/+58
| |