Skip to content

(PE-37235) Verify and update documentation on add_compiler #429

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

Merged
merged 10 commits into from
Aug 21, 2024
33 changes: 33 additions & 0 deletions documentation/add_compiler.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Add Compiler

The `peadm::add_compiler` plan can be used to add a new compiler to a PE cluster or replace an existing one with new configuration.

## Add a compiler to an existing PE cluster

Prepare to run the plan using a params.json file such as this one:

```json
{
"avail_group_letter": "A",
"compiler_host": "pe-xl-compiler-0.lab1.puppet.vm",
"dns_alt_names": [ "puppet", "puppet.lab1.puppet.vm" ],
"primary_host": "pe-xl-core-0.lab1.puppet.vm",
"primary_postgresql_host": "pe-psql-6251cd-0.us-west1-a.c.slice-cody.internal",
}
```

See the [install](install.md#reference-architectures) documentation for a list of supported architectures.


## Running the add_compiler plan
```
bolt plan run peadm::add_compiler --params @params.json
```

This command will retrieve the current PEADM configuration to determine the setup rules needed for a compiler's secondary PuppetDB instances. The plan will configure the primary with appropriate rules for allowing access from the new compiler. On the primary, the `puppet` service is stopped and the `pe-postgresql` service is reloaded. If required, a puppet agent is be installed. The compiler agent's certificate is be regenerated to include required data with `peadm::subplans::component_install`. Puppet agent will run on the following components
* _\<compiler-host\>_
* _\<primary_postgresql_host\>_
* _\<replica host\>_
* _\<primary_postgresql_host\>_

The `puppet` service is then restarted.
2 changes: 1 addition & 1 deletion plans/add_compiler.pp
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
# On <primary_postgresql_host> run the puppet agent
run_task('peadm::puppet_runonce', $primary_postgresql_target)

# On replica puppetdb run the puppet agent
# On replica host run the puppet agent
run_task('peadm::puppet_runonce', $replica_puppetdb_target)

# On <primary_postgresql_host> start puppet.service
Expand Down
Loading