| SYSTEMD-IMDS(1) | systemd-imds | SYSTEMD-IMDS(1) |
.SH "NAME" systemd-imds, systemd-imds-import.service - Cloud IMDS
(Instance Metadata Service) tool
.SH "SYNOPSIS"
.PP systemd-imds-import.service
.HP 312u
systemd-imds [OPTIONS...] [KEY]
.SH "DESCRIPTION"
.PP systemd-imds is a tool for acquiring data from IMDS (Instance
Metadata Service), as provided in many cloud environments. It is a client to
systemd-imdsd@.service(8), and provides access to IMDS data from
shell environments.
.PP The tool can operate in one of five modes:
.PP In addition, when invoked as a Varlink service (i.e. via socket
activation through systemd-imds-metrics.socket), systemd-imds acts as
an io.systemd.Metrics provider for systemd-report(1). It
exposes the detected cloud vendor and the well-known hostname, region, zone,
ipv4-public and ipv6-public fields as metrics in the
io.systemd.InstanceMetadata. namespace. The data is acquired on demand from
systemd-imdsd@.service(8), benefiting from its local cache.
.SH "OPTIONS AND COMMANDS"
.PP --well-known=, -K
Takes one of hostname, region, zone, ipv4-public, ipv6-public, ssh-key,
userdata, userdata-base, userdata-base64. Acquires a specific
"well-known" field from IMDS. Many of these fields are commonly
supported by various IMDS implementations, but typically some fields are
not. Note that if --well-known=userdata-base is used an additional
subkey should be specified as positional argument, which encodes the
specific userdata item to acquire.
Added in version 261.
.RE
.PP --refresh=
Takes a time in seconds as argument, and indicates the required
"freshness" of the data, in case cached data is used.
Added in version 261.
.RE
.PP --cache=
Takes a boolean. If set to false local caching of IMDS is disabled, and the
data is always acquired fresh from the IMDS endpoint.
Added in version 261.
.RE
.PP --userdata, -u
Acquire this instance's IMDS user data, if available. See above for
details.
Added in version 261.
.RE
.PP --import
Acquires IMDS data and writes relevant fields as credentials to
/run/credstore/. This currently covers:
.sp
This command is invoked by the systemd-imds-import.service run at boot.
Added in version 261.
.RE
.PP -h, --help
Print a short help text and exit.
.RE
.PP --version
Print a short version string and exit.
.RE
.SH "EXIT STATUS"
.PP On success, 0 is returned, a non-zero failure code otherwise.
.SH "SEE ALSO"
.PP systemd(1), systemd-imdsd@.service(8),
systemd-imds-generator(8), systemd-report(1),
systemd.system-credentials(7)
| systemd 262.2 |