cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
pclark
AppDynamics Team (Retired)

What do I need to know about using the sample script to build my own Puppet module?

 

Every deployment is different, so this task doesn't lend itself to one all-inclusive Puppet script maintained by AppDynamics. However, the attached sample script can help you get started on your own Puppet module.

 

Table of Contents

 

What do I need to know about the Puppet sample’s environment and components

This sample script is intended for a Linux/Tomcat deployment. The script is relatively straightforward, and is intended to serve as a rough framework for building a script appropriate for your specific environment. Definitely edit it as appropriate for your environment and test out your config! 

 

Puppet configuration essentials

If you haven't used Puppet before, we recommend running through the first two sections of the Puppet Quick Start Guide

 

What guidelines are there for creating my own Puppet module from the sample?

 

  1. The java_agent.zip file needs to be unzipped into the prospect's Puppet modules directory (/etc/puppet/environments/production/modules/ by default).

    It contains 4 subdirectories: manifests, templates, files, and tests:
    • /manifests contains the main Puppet script, init.pp

    • /templates contains the catalina.sh template file (see lines 236-238) for how the init.pp variables are inserted.

      Common system variables you would use can be found here: https://puppet.com/docs/puppet/6.19/lang_variables.html

    • /files contains the AppServerAgent.zip — Replace this with the version of AppServerAgent.zip that you'd like to deploy

    • /tests is not used for this module  

  2. Within init.pp you see the list of variables used for the deployment. You need to set these as appropriate for the target system.

    For SaaS or other configurations, be sure to add the appropriate Java configuration properties to the command line.

  3. If you already deploy a customized catalina.sh, you may want to inherit that template file or you may need to get more creative. A simple line replace should suffice.
Comments
Aaron.Jacobs
AppDynamics Team

This doc needs to be updated.  The links show 'page not found' on the puppet site -- 

https://docs.puppetlabs.com/pe/latest/quick_start.html

https://docs.puppetlabs.com/learning/variables.html

 

Claudia.Landivar
AppDynamics Team (Retired)

Thank you, @Aaron.Jacobs. I'll look into it and post resolution here.

 

The article has been revised with updated links and minor structural and formatting changes meant to improve usability.

 

Claudia Landivar

Community Manager & Editor, Knowledge Base

Version history
Last update:
‎10-29-2020 01:06 PM
Updated by:
On-Demand Webinar
Discover new Splunk integrations and AI innovations for Cisco AppDynamics.


Register Now!

Observe and Explore
Dive into our Community Blog for the Latest Insights and Updates!


Read the blog here