There's also a runtime flag in `/run/ostree-booted` that will be set to
`1` if the system is an "atomic" or rpm-ostree based install. That's
how the Ansible content I've seen and used test's for `is_atomic`.
It's not something built in, so it's a local fact set during run of the
playbook.
I'm not familiar with docker-machine, so can you elaborate on how
`/etc/os-release` would help here? Can docker-machine extract that file
without having to SSH to the host? We've talked previously about asking
for an "Atomic" flag in os-release or fedora-release, but there haven't
been a lot of concrete use cases to base it on.
- Matt M
On 11/09/2015 02:26 PM, Jeremy Eder wrote:
The tuned software keys off of this file:
-bash-4.2# cat /etc/system-release-cpe
cpe:/o:redhat:enterprise_linux:7.2:ga:atomic-host
On Mon, Nov 9, 2015 at 2:13 PM, Charlie Drage <cdr...@redhat.com
<mailto:cdr...@redhat.com>> wrote:
I'm working on docker-machine integration for atomic host's. The
problem I'm facing is the fact that "atomic" isn't defined under
/etc/os-release, it's simply "fedora" or "centos" as the id.
At the moment the only viable way to determine if an OS is an atomic
host or not would be 'ls /ostree' or 'rpm-ostree status' (correct me
if I'm wrong). Unfortunately it would be bad coding practice to
require SSH'ing into a machine via the Docker machine generic driver
in order to determine if it is atomic or not before proceeding.
Ideally, having this information within /etc/os-release would be the
most ideal.
Is there a possibility to add a description to /etc/os-release? Or
perhaps using fedora22-atomic, fedora23-atomic, etc as a release
id? Creating a
standardized way for scripts (Ansible, docker machine, etc.) to detect
if this is an atomic host or not?
I did try 'uname -r' as well to try and determine if there was a
specifically named kernel version for atomic hosts as an alternative
to determining if it's an atomic host, but to no avail.
Best regards,
--
Charlie Drage
Red Hat - OSAS Team / Project Atomic
4096R / 0x9B3B446C
http://pgp.mit.edu/pks/lookup?op=get&search=0x622CDF119B3B446C
--
-- Jeremy Eder