-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Documentation for general installation in containerized environments #3355
base: master
Are you sure you want to change the base?
Conversation
fa645e7
to
5e7da00
Compare
I am unable to figure out the reason for failure of check with: Any help to deal with this cryptic error is appreciated. |
Your files have extra spaces in them, at the ends of multiple lines.
That will edit the file, removing those extra unnecessary spaces. |
The extra spaces (particularly |
@olehermanse, Hope that's fine. |
What requirements? This is not required.
No, remove these, they are not necessary.
No, that change is not correct, remove it. We want to strip trailing whitespace. You don't need trailing whitespace nor html tags ( |
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
Bootstrap cfengine-host to cfengine-hub: | ||
|
||
```command | ||
$ docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$ docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}" | |
docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Humm, this didn't work for me.
docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}"
bash: line 1: /usr/local/sbin/cf-agent: No such file or directory
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that's because we miss to read
Rest of the installation steps remain the same as for cfengine-hub.
I've removed this and added granular steps instead.
After the fix
cfengine$ docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}"
notice: Bootstrap mode: implicitly trusting server, use --trust-server=no if server trust is already established
notice: Trusting new key: MD5=e5da40ee8037819f033e972d0fa24bcf
R: Bootstrapping from host '172.17.0.2' via built-in policy '/var/cfengine/inputs/failsafe.cf'
R: This autonomous node assumes the role of voluntary client
R: Updated local policy from policy server
R: Triggered an initial run of the policy
R: Restarted systemd unit cfengine3
notice: Bootstrap to '172.17.0.2' completed successfully
While working on this part I realized that the Dockerfile and docker compose
based approach is much efficient and faster as the installation happens only once.
However, for understanding sake, we should maintain this approach for deploying containers individually as well.
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@me-coder thank you for this contribution. Overall it's quite a nice addition. Looking forward to having this in the docs.
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
sorting: 80 | ||
--- | ||
|
||
These instructions describe how to download and install the latest version of CFEngine Community in a docker containerized environment using pre-compiled rpm packages for ubi9 images. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know of any other place we reference ubi images. Might be worth some description of what a ubi9 image is.
Red Hat Universal Base Images (UBI) are OCI-compliant container base operating system images with complementary runtime languages and packages that are freely redistributable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added these references:
Bootstrap cfengine-host to cfengine-hub: | ||
|
||
```command | ||
$ docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Humm, this didn't work for me.
docker exec cfengine-host bash -c "/usr/local/sbin/cf-agent --bootstrap ${CFENGINE_HUB_IP}"
bash: line 1: /usr/local/sbin/cf-agent: No such file or directory
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
Start service cfengine-demo | ||
|
||
```command | ||
$ docker compose -f compose.yaml --verbose up -d |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$ docker compose -f compose.yaml --verbose up -d | |
docker compose -f compose.yaml --verbose up -d |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I get an error running this.
validating /tmp/test/compose.yaml: services.cfengine-host.depends_on must be a list
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, there was an indentation issue in the config.yaml
. I've fixed it.
Also, added a linting step for Dockerfile and compose.yaml to capture such issues better,
getting-started/installation/general-installation/installation-community-containerized.markdown
Outdated
Show resolved
Hide resolved
@@ -2,7 +2,7 @@ | |||
layout: default | |||
title: Installing Enterprise on CoreOS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@olehermanse Perhaps this should be re-titled to Installing Enterprise using disk image
Or actually, maybe we need to drop this page completely. I don't see that we are still publishing a disk image since CoreOS is died (and now it's resurrected under Fedora https://fedoraproject.org/coreos/ ).
Hi @olehermanse, @nickanderson, I made the suggested changes and also a few enhancements to the document and force pushed it as a amended single commit. I submitted a single commit as I always feel it's cleaner, could be fast-forwarded and there were changes which I could easily edit as a batch in VSCode editor. Kindly re-consider the review with the applied changes. |
The CFEngine installation guide is missing out on containers.
This PR is an attempt to project the capability of CFEngine with containers (using ubi9-init images).
There are a few limitations due to the nature of CFEngine (requires privileged mode and container is required to have systemd, which need initialization with /var/sbin/init).
However, it still gives a good ability to test CFEngine in containerized environments in full capacity, without the need to have a bulky multi VM setup.
Hope the moderator team finds this useful and decides to integrate it into the docs.