Pull request #22: Feat/nm and docs
Merge in ICO/coreos from feat/nm-and-docs to master * commit '64653a83bb8adce129e6871b76962da2e95e7de1': docs(showcase): add a showcase to document networkmanager, podman and cockpit refactor(container): rename the container image feature to podman feat(networkmanager): add networkmanager as an image feature fix(coreos-generic-machine/vm.inc): generate wic.xz
|
|
@ -22,6 +22,7 @@ same structures.
|
|||
:caption: Introduction and Overview
|
||||
|
||||
Quick Build <quick-build>
|
||||
Features Showcase <showcase/index>
|
||||
Setting up a CoreOS based distro <using-coreos>
|
||||
Building and using a Container Image <using-container>
|
||||
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ CoreOS doesn't define any custom distro feature for now, but the
|
|||
can be used.
|
||||
|
||||
.. index:: IMAGE_FEATURES
|
||||
.. _ref-features-image:
|
||||
|
||||
Image Features
|
||||
==============
|
||||
|
|
@ -36,6 +37,13 @@ these features is as follows:
|
|||
- *tools-debug:* Installs debugging tools such as ``strace`` and ``gdb``.
|
||||
- *tools-profile:* Installs profiling tools such as ``valgrind`` and ``perf``.
|
||||
- *ssh-server:* Installs the Dropbear minimal SSH server.
|
||||
- *podman:*: Installs the Podman container runtime
|
||||
- *networkmanager:* Installs the NetworkManager daemon and command line client
|
||||
- *cockpit:* Installs the cockpit web interface
|
||||
- *dev-tools:* Install some developer command line tools
|
||||
|
||||
The *cockpit* and *dev-tools* feature are special, as they will automatically
|
||||
add package based on the other image feature that are enabled.
|
||||
|
||||
:external:ref:`IMAGE_FEATURES <ref-features-image>` defined in OpenEmbedded-Core
|
||||
are also available, but note that the
|
||||
|
|
|
|||
|
|
@ -0,0 +1,89 @@
|
|||
.. _ref-cockpit:
|
||||
|
||||
Cockpit Web Interface
|
||||
=====================
|
||||
|
||||
The Cockpit Web Interface is an easy-to-use web based interface made to manage
|
||||
a Linux based server. It intentionally uses standard system API like `systemd`,
|
||||
`pam`, `networkmanager` making it easily integrable and interoperable on
|
||||
any Linux operating system using these programs.
|
||||
|
||||
.. image:: cockpit/overview.png
|
||||
|
||||
.. important::
|
||||
|
||||
Providing and supporting a web management interface is out of the scope of
|
||||
CoreOS. We provide some facilities to install this web interface as it's
|
||||
available in `meta-openembedded` and we find it useful for developer.
|
||||
|
||||
The Cockpit Web Interface can be installed on an image by adding `cockpit` to
|
||||
the :ref:`IMAGE_FEATURES <ref-features-image>` variable. You can then access
|
||||
the web interface on the port 9090: `https://TARGET_IP:9090`
|
||||
|
||||
.. hint::
|
||||
Cockpit use standard Linux authentification method. The simplest way to
|
||||
get a login is to enable the `debug-tweak`
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>`, then login with `root` as
|
||||
username and an empty password.
|
||||
|
||||
See https://cockpit-project.org/guide/latest/authentication for more info
|
||||
|
||||
When the `cockpit` `IMAGE_FEATURES`` is used, the following feature of are
|
||||
availabe:
|
||||
|
||||
Dashboard
|
||||
---------
|
||||
|
||||
The dashboard allows seeing some system statistic in real time.
|
||||
|
||||
.. image:: cockpit/dashboard.png
|
||||
|
||||
.. hint::
|
||||
The statistics are not stored, so they are only available when the dashboard
|
||||
page is open
|
||||
|
||||
Logs Viewer
|
||||
-----------
|
||||
|
||||
The log viewer allows seeing the log from `journalctl`.
|
||||
|
||||
.. image:: cockpit/log.png
|
||||
|
||||
Accounts management
|
||||
-------------------
|
||||
|
||||
The account management allow creating and managing users. For existing user, the
|
||||
account can be locked, the password changed and SSH public key can be added.
|
||||
|
||||
|
||||
.. image:: cockpit/accounts.png
|
||||
|
||||
Services management
|
||||
-------------------
|
||||
|
||||
The services page allows managing `systemd` service. Service can be started,
|
||||
restarted, stopped, enabled or disabled. Logs related to the service can also be
|
||||
viewed easily.
|
||||
|
||||
.. image:: cockpit/services.png
|
||||
|
||||
Web Terminal
|
||||
------------
|
||||
|
||||
The terminal page gives access to a web terminal, allowing to interact with the
|
||||
shell of the device.
|
||||
|
||||
.. image:: cockpit/terminal.png
|
||||
|
||||
Additional plugins
|
||||
------------------
|
||||
|
||||
Additional plugin can be installed for `cockpit`, like `podman-cockpit` that
|
||||
allow to manage podman container from the cockpit web interface. When possible,
|
||||
CoreOS automatically add the corresponding `cockpit` plugin when additional
|
||||
features are added via :ref:`IMAGE_FEATURES <ref-features-image>`.
|
||||
|
||||
As an example, the `cockpit-podman` package is automatically installed if
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` contains both `cockpit` and `podman`.
|
||||
|
||||
These plugins are documented in the corresponding features showcase page.
|
||||
|
After Width: | Height: | Size: 51 KiB |
|
After Width: | Height: | Size: 70 KiB |
|
After Width: | Height: | Size: 62 KiB |
|
After Width: | Height: | Size: 115 KiB |
|
After Width: | Height: | Size: 110 KiB |
|
After Width: | Height: | Size: 78 KiB |
|
|
@ -0,0 +1,15 @@
|
|||
|
||||
=================
|
||||
Features Showcase
|
||||
=================
|
||||
|
||||
|
|
||||
|
||||
.. toctree::
|
||||
:caption: Table of Contents
|
||||
:numbered:
|
||||
:maxdepth: 1
|
||||
|
||||
cockpit
|
||||
networkmanager
|
||||
podman
|
||||
|
|
@ -0,0 +1,50 @@
|
|||
.. _ref-networkmanager:
|
||||
|
||||
NetworkManager
|
||||
==============
|
||||
|
||||
NetworkManager is the standard Linux network configuration tool suite. It
|
||||
supports large range of networking setups, from desktop to servers and
|
||||
mobile and integrates well with popular desktop environments and server
|
||||
configuration management tools.
|
||||
|
||||
https://networkmanager.dev/
|
||||
|
||||
NetworkManager can be installed on an image by adding `networkmanager` to
|
||||
the :ref:`IMAGE_FEATURES <ref-features-image>` variable. This provide the
|
||||
NetworManager daemon and the `nmcli` tools.
|
||||
|
||||
nmtui
|
||||
-----
|
||||
|
||||
The `nmtui` package provide a terminal user interface for NetworkManager.
|
||||
|
||||
.. only:: html
|
||||
|
||||
.. image:: networkmanager/nmtui.gif
|
||||
|
||||
.. only:: latex
|
||||
|
||||
.. image:: networkmanager/nmtui.png
|
||||
|
||||
|
||||
This package is automatically installed if both `networkmanager` and `dev-tools`
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` are enabled.
|
||||
|
||||
cockpit-networkmanager
|
||||
----------------------
|
||||
|
||||
The `cockpit-networkmanager` package provide a :ref:`cockpit <ref-cockpit>`
|
||||
plugin that allow to manage NetworkManager from the
|
||||
:ref:`cockpit <ref-cockpit>` web interface.
|
||||
|
||||
.. only:: html
|
||||
|
||||
.. image:: networkmanager/cockpit-networkmanager.gif
|
||||
|
||||
.. only:: latex
|
||||
|
||||
.. image:: networkmanager/cockpit-networkmanager.png
|
||||
|
||||
This package is automatically installed if both `networkmanager` and `cockpit`
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` are enabled.
|
||||
|
After Width: | Height: | Size: 4.2 MiB |
|
After Width: | Height: | Size: 46 KiB |
|
After Width: | Height: | Size: 1.6 MiB |
|
After Width: | Height: | Size: 15 KiB |
|
|
@ -0,0 +1,64 @@
|
|||
|
||||
Podman Container Manager
|
||||
=========================
|
||||
|
||||
Podman is a tool to manage pods and containers. Pods come from Kubernetes, that
|
||||
define a pod this way:
|
||||
|
||||
A Pod (as in a pod of whales or pea pod) is a group of one or more
|
||||
containers, with shared storage and network resources, and a specification
|
||||
for how to run the containers.
|
||||
|
||||
.. important::
|
||||
|
||||
CoreOS doesn't mandate the use of `podman` for running container.
|
||||
|
||||
But as we can't support every existing container runtime, `podman` is the
|
||||
only documented/supported way to run container.
|
||||
|
||||
Other container runtimes are available inside the open source
|
||||
`meta-virtualization` layer that is available inside CoreOS.
|
||||
|
||||
Podman can be installed on an image by adding `podman` to the
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` variable.
|
||||
|
||||
By default, this will just provide the `podman` command. The `podman` command
|
||||
is similar to the `docker` one, and most command should work by replacing
|
||||
`docker` by `podman`. See https://docs.podman.io/en/latest/Commands.html for
|
||||
more info.
|
||||
|
||||
podman-tui
|
||||
----------
|
||||
|
||||
The `podman-tui` package provide a terminal user interface for `podman`. This
|
||||
package is automatically installed if both `podman` and `dev-tools`
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` are enabled.
|
||||
|
||||
.. only:: html
|
||||
|
||||
.. image:: podman/podman-tui.gif
|
||||
|
||||
.. only:: latex
|
||||
|
||||
.. image:: podman/podman-tui.png
|
||||
|
||||
The above image was copied from https://github.com/containers/podman-tui/blob/e29e47fd392647033dc1c0cc0eaefa1f62661b98/docs/podman-tui.gif
|
||||
|
||||
cockpit-podman
|
||||
--------------
|
||||
|
||||
The `cockpit-podman` package provide a :ref:`cockpit <ref-cockpit>` plugin that
|
||||
allow to manage `podman` from the :ref:`cockpit <ref-cockpit>` web interface.
|
||||
|
||||
This package is automatically installed if both `podman` and `cockpit`
|
||||
:ref:`IMAGE_FEATURES <ref-features-image>` are enabled.
|
||||
|
||||
|
||||
.. only:: html
|
||||
|
||||
.. image:: podman/cockpit-podman.gif
|
||||
|
||||
.. only:: latex
|
||||
|
||||
.. image:: podman/cockpit-podman.png
|
||||
|
||||
|
After Width: | Height: | Size: 3.7 MiB |
|
After Width: | Height: | Size: 89 KiB |
|
After Width: | Height: | Size: 661 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
|
@ -11,7 +11,7 @@ PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
|
|||
|
||||
MACHINE_EXTRA_RRECOMMENDS += "kernel-modules linux-firmware"
|
||||
|
||||
IMAGE_FSTYPES += "ext4 wic wic.bmap wic.vmdk"
|
||||
IMAGE_FSTYPES += "ext4 wic wic.xz wic.bmap wic.vmdk"
|
||||
|
||||
WKS_FILE ?= "generic-uefi.wks.in"
|
||||
do_image_wic[depends] += "gptfdisk-native:do_populate_sysroot"
|
||||
|
|
|
|||
|
|
@ -6,9 +6,13 @@ FEATURE_PACKAGES_tools-debug = "packagegroup-core-tools-debug"
|
|||
FEATURE_PACKAGES_tools-profile = "packagegroup-core-tools-profile"
|
||||
FEATURE_PACKAGES_hwcodecs = "${MACHINE_HWCODECS}"
|
||||
|
||||
FEATURE_PACKAGES_container = "packagegroup-coreos-container"
|
||||
FEATURE_PACKAGES_container-dev-tools = "packagegroup-coreos-container-dev-tools"
|
||||
FEATURE_PACKAGES_container-cockpit = "cockpit-podman"
|
||||
FEATURE_PACKAGES_podman = "podman"
|
||||
FEATURE_PACKAGES_podman-dev-tools = "podman-tui"
|
||||
FEATURE_PACKAGES_podman-cockpit = "cockpit-podman"
|
||||
|
||||
FEATURE_PACKAGES_networkmanager = "networkmanager networkmanager-nmcli"
|
||||
FEATURE_PACKAGES_networkmanager-dev-tools = "networkmanager-nmtui"
|
||||
FEATURE_PACKAGES_networkmanager-cockpit = "cockpit-networkmanager"
|
||||
|
||||
# The cockpit feature automatically install the corresponding
|
||||
# *-cockpit FEATURES_PACKAGES for any image features
|
||||
|
|
@ -16,7 +20,7 @@ FEATURE_PACKAGES_cockpit = "packagegroup-coreos-cockpit ${@get_feature_packages_
|
|||
|
||||
# The dev-tools feature automatically install the corresponding
|
||||
# *-dev-tools FEATURES_PACKAGES for any image features
|
||||
FEATURE_PACKAGES_dev-tools = "${@get_feature_packages_with_suffix('dev-tool', d)}"
|
||||
FEATURE_PACKAGES_dev-tools = "${@get_feature_packages_with_suffix('dev-tools', d)}"
|
||||
|
||||
def get_feature_packages_with_suffix(suffix, d):
|
||||
"""
|
||||
|
|
@ -58,6 +62,7 @@ PACKAGE_EXCLUDE_COMPLEMENTARY:append = "${@bb.utils.contains_any('PACKAGE_INSTAL
|
|||
# IMAGE_FEATURES_CONFLICTS_foo = 'bar1 bar2'
|
||||
# An error exception would be raised if both image features foo and bar1(or bar2) are included
|
||||
|
||||
|
||||
COREOS_IMAGE_BASE_INSTALL = '\
|
||||
packagegroup-core-boot \
|
||||
packagegroup-base-extended \
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ BBFILE_PRIORITY_meta-belden-coreos = "6"
|
|||
LAYERDEPENDS_meta-belden-coreos = "\
|
||||
core \
|
||||
openembedded-layer \
|
||||
networking-layer \
|
||||
virtualization-layer \
|
||||
webserver \
|
||||
"
|
||||
|
|
|
|||
|
|
@ -3,5 +3,5 @@ functionality installed."
|
|||
|
||||
inherit coreos-image
|
||||
|
||||
IMAGE_FEATURES += "ssh-server container dev-tools cockpit"
|
||||
IMAGE_FEATURES += "ssh-server podman dev-tools cockpit networkmanager"
|
||||
IMAGE_INSTALL:append = " packagegroup-core-full-cmdline"
|
||||
|
|
|
|||
|
|
@ -1,18 +0,0 @@
|
|||
SUMMARY = "Add containers runtime and management"
|
||||
DESCRIPTION = "Add containers runtime and management"
|
||||
|
||||
inherit packagegroup
|
||||
|
||||
|
||||
PACKAGES = "\
|
||||
${PN} \
|
||||
${PN}-dev-tools \
|
||||
"
|
||||
|
||||
RDEPENDS:${PN} = "\
|
||||
podman \
|
||||
"
|
||||
|
||||
RDEPENDS:${PN}-dev-tools = "\
|
||||
podman-tui \
|
||||
"
|
||||