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 architecture or replace an existing one with new configuration.

## Add compiler to an exising PE instance

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 call will retreive the current peadm config to determain the setup rules needed for a compiler's secondary PuppetDB instances. The provided server will be configured with the appropriate rules for Puppet Server access from compiler. The puppet.service will be stopped and the pe-postgresql.service will be reloaded. If required and agent will be installed and regenerated agent certificate to add required data with peadm::subplans::component_install. Puppet agent will run on the following components
* _\<compiler-host\>_
* _\<primary_postgresql_host\>_
* _\<replica postgres host\>_
* _\<primary_postgresql_host\>_

The puppet.service will then be 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 postgres host run the puppet agent
run_task('peadm::puppet_runonce', $replica_puppetdb_target)

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