Skip to content
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

Backport docker examples for 2018 #99

Merged
merged 9 commits into from
May 29, 2020
Merged

Conversation

logicminds
Copy link
Contributor

The docker examples located in the spec/docker directory were previously only in master. However, because testing needs to be performed for a future PE LTS upgrade we need to provision a 2018 stack. The 2018 stack can only be provisioned from the 0.4.x branch, thus the reason for back porting the changes to this branch.

What this means is that we can now easly provision and upgrade 2018 stacks with docker as we do in the present 2019 versions of PE.

This change set also required me to back port the sign_csr and submit_csr tasks that were originally modified in the master branch. As a result we fixed a bug in the 0.4.x branch that was causing subsequent runs of the provision to fail. Additionally, standard size stacks were unable to be provisioned due to a bug in the plan with AIO stacks.

  * This backports a number of commits from the master branch
    pertaining to testing on docker.

  * Previously working on this module required a buildout
    of a puppet infrastructure with VMs or cloud providers.
    Which can sometimes be costly or take hours to deploy.

    This commit uses containers and docker-compose to produce
    sample environments for each architecuture in order to
    perform rapid prototyping or test the functionality of this module
    and the puppet infra command.

    The architectures supported in this command are:
      * standard, stadard-ha
      * large, large-ha
      * extra-large, extra-large-ha

    While there are many other possiblites and combinations of amount
    of servers and containers these are the current choices.

    For more information please see documention/docker_examples.md
  * When using the example docker containers you will
    have the ability to see what files are copied over to the
    system for inspection.
  * previously the example docker files used a static
    directory for bolt scripts.  This removes the script-dir
    so bolt will create a unique one each time.
  * Also adds the live_audit script to systemd.
    This will cause systemd to startup the audit on boot
    so all bolt files will be copied over to /tmp/backup
    for investigation.
  * When running puppetdb queries in the container it is helpful to
    have the the config file setup already. This commit configures
    the puppetdb.conf file on the puppet servers.
  * The docker container for bolt was having some encoding issues
    after running a plan.  This fixes that issue so the plan/command
    does not fail.

  * Only applies to the example docker containers
  * This only applies to our example docker containers.
    If the docker host reboots, the containers will now
    restart upon reboot. Was just too annoying before to always
    have to start up the machines again.
  * previously if the sign or request cert tasks were
    run twice, the tasks would fail.  This adds idempotency
    to the submit_csr tasks.
  * Also backports the sign_csr and submit_csr tasks and updates the
    install plan to use sign_csr instead of the puppet apply.
@logicminds logicminds requested a review from a team as a code owner May 28, 2020 22:09
@@ -301,10 +301,11 @@
apply($master_host) { include pe_xl::setup::master }.pe_xl::print_apply_result
}

Copy link
Contributor Author

@logicminds logicminds May 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Below is where a bug was introduced when agent_installer_targets was empty. Now fixed with the new task and conditional around the task.

@reidmv reidmv merged commit 2827dc3 into puppetlabs:0.4.x May 29, 2020
@logicminds logicminds deleted the docker_0.4.x branch June 29, 2020 19:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants