Skip to content

Connection Templates

Connection templates form the foundation of device connectivity in rConfig V8, defining how the system authenticates, connects, and interacts with network devices across your infrastructure. Understanding how to create and manage templates effectively ensures reliable configuration retrieval, reduces connection failures, and enables support for diverse network equipment from multiple vendors.

This guide covers template architecture, creation workflows, YAML configuration standards, troubleshooting techniques, and best practices for maintaining a scalable template library that supports your organization’s network management requirements.

Connection templates serve as reusable configuration blueprints that specify the connection parameters, authentication methods, CLI prompts, command syntax, and behavior patterns for network devices. Rather than configuring connection details individually for each device, templates enable you to define these parameters once and apply them across multiple devices of the same type or vendor family.

Templates address several critical challenges in network configuration management:

Consistency Across Device Fleet: Organizations managing hundreds or thousands of network devices need standardized connection methods. Templates ensure that all devices of a specific type use identical connection parameters, reducing configuration drift and troubleshooting complexity.

Multi-Vendor Support: Modern networks include equipment from various manufacturers, each with unique CLI behaviors, prompt patterns, and command syntax. Templates encapsulate these vendor-specific requirements, allowing rConfig to communicate effectively with diverse device types.

Simplified Device Onboarding: When adding new devices to rConfig, administrators can assign pre-configured templates rather than manually configuring connection parameters for each device. This accelerates deployment and reduces human error.

Centralized Maintenance: When connection requirements change (such as adjusted timeout values or modified privilege escalation commands), updating the template automatically propagates changes to all devices using that template.

Each connection template is defined using YAML (YAML Ain’t Markup Language), a human-readable data serialization format that balances clarity with technical precision. The template structure includes:

  • Connection Protocol Settings: Defines whether to use SSH, Telnet, or other protocols
  • Authentication Parameters: Specifies username and password prompt patterns (not actual credentials)
  • CLI Prompt Recognition: Patterns that identify when the device is ready for commands
  • Command Execution Behavior: Timeout values, paging settings, and command delimiters
  • Privilege Escalation: Enable mode access and privilege level commands
  • Vendor-Specific Quirks: Special handling for unique device behaviors

Understanding how templates relate to devices is essential for effective configuration management:

  1. One Template Per Device: Each device in rConfig can be assigned exactly one connection template. This ensures predictable connection behavior and prevents conflicting configuration parameters.

  2. Multiple Devices Per Template: A single template can be assigned to unlimited devices. This is the primary mechanism for scaling configuration management across device fleets.

  3. Template Flexibility: While templates are labeled for specific vendors (such as “Cisco IOS”), they often work with devices from other manufacturers that use similar CLI patterns. Testing is recommended when applying templates across vendor boundaries.

  4. No Limit on Template Count: Organizations can create unlimited templates to accommodate diverse network equipment, custom device configurations, or specialized connection requirements.

  5. Template Portability: Templates use a standardized format compatible across rConfig versions, allowing organizations to share templates and leverage community-contributed configurations.

rConfig V8 includes four default connection templates that cover common network device types:

  • Cisco IOS/IOS-XE: Standard Cisco router and switch platforms
  • Cisco NXOS: Nexus data center switching platforms
  • Cisco ASA: Adaptive Security Appliance firewalls
  • Generic SSH: Basic SSH connectivity for Linux/Unix systems

While labeled for Cisco platforms, these templates frequently support devices from other manufacturers including Arista, HP/Aruba, Juniper (with modifications), and other vendors using similar CLI patterns. Organizations should verify compatibility through testing before production deployment.

The rConfig project maintains an open-source template repository on GitHub containing templates for dozens of vendor platforms and device types. This community-driven resource provides:

  • Tested templates for major network equipment vendors
  • Specialty templates for niche or legacy equipment
  • Template development documentation and YAML standards
  • Community contributions from rConfig users worldwide

The templates interface provides centralized management for your connection template library. The main view displays all available templates in a searchable, sortable table format.

rConfig V8 Templates main view showing template list with name, protocol, and action columns Templates Main View

The interface provides several key functions:

  • Template List: View all configured templates with key metadata
  • Quick Search: Filter templates by name or protocol
  • Add Template: Create new custom templates
  • Repository Import: Bulk import templates from the GitHub repository
  • Edit/Delete Actions: Modify or remove existing templates
  • Template Testing: Assign templates to test devices for validation

rConfig V8 streamlines template library expansion through one-click repository import functionality. This feature eliminates manual template creation by downloading the entire community template collection directly from the official GitHub repository.

Repository import button with GitHub icon in templates interface Repository Import Button

To import the complete template repository:

  1. Navigate to Settings → Templates in the rConfig interface
  2. Click the Import button with the GitHub icon
  3. rConfig connects to https://github.com/rconfig/rConfig-templates
  4. All available templates download and install automatically
  5. The template list refreshes to display newly imported templates

The import process is non-destructive—existing custom templates remain unchanged, and duplicate templates (based on name) will not overwrite your customized versions.

Template creation and modification occurs through rConfig’s integrated YAML editor, which provides syntax highlighting and structured formatting for template configuration files.

Step 1: Access Template Creation

  • Navigate to Settings → Templates
  • Click the Add Template button
  • The YAML editor opens with a blank template structure

Step 2: Configure Basic Parameters

  • Define template name (descriptive, indicating vendor/platform)
  • Specify connection protocol (SSH, Telnet, etc.)
  • Set authentication prompt patterns

Step 3: Define CLI Behavior

  • Configure command prompt recognition patterns
  • Set timeout values appropriate for device response times
  • Define paging control commands if applicable

Step 4: Test and Validate

  • Save the template
  • Assign to a test device
  • Execute connection tests using CLI commands
  • Refine parameters based on connection behavior

Step 5: Production Deployment

  • Once validated, assign to production devices
  • Monitor initial connections for issues
  • Document any device-specific requirements

The template editor provides a direct interface to YAML configuration files. Understanding YAML syntax requirements ensures error-free template creation:

Comments and Documentation

  • All comments begin with the # character
  • Comments can appear on their own line or at the end of configuration lines
  • Default templates include extensive comments explaining each parameter
  • Retain existing comments for documentation purposes, or add your own

Syntax Requirements

  • Indentation: YAML uses spaces (not tabs) for structure—typically 2 or 4 spaces per level
  • Quotation Marks: String values may require single or double quotes, particularly when containing special characters
  • Colons and Spaces: Key-value pairs use the format key: value with a space after the colon
  • List Items: Array items begin with a dash and space - item
  • Case Sensitivity: YAML keys and values are case-sensitive

Critical Parameters

Username and Password Prompts The username and password keys define the CLI prompt patterns that rConfig watches for during authentication. These keys specify prompt text patterns, not actual credentials:

username: "Username:" # The prompt the device displays
password: "Password:" # The password prompt pattern

Device credentials are stored separately in the device configuration and provided at connection time. Never include actual usernames or passwords in template files.

Timeout Configuration The timeout parameter controls how long rConfig waits for device responses before declaring a connection failure:

timeout: 15 # Timeout in seconds

Common YAML Errors

  • Extra or missing spaces in indentation
  • Missing colons after keys
  • Unmatched quotation marks
  • Incorrect list formatting
  • Mixed tabs and spaces
  • Trailing spaces at line ends

The YAML editor does not include real-time syntax validation. Syntax errors may not appear until template execution, resulting in connection failures. Careful attention to formatting prevents these issues.

Effective template development requires iterative testing and refinement. The recommended workflow:

1. Create Test Environment

  • Identify a non-production device for testing
  • Ensure console or out-of-band access in case of connection issues
  • Document current device configuration for rollback if needed

2. Assign Template to Test Device

  • Navigate to Devices → Device Management
  • Edit the test device configuration
  • Assign the new template

3. Execute Connection Tests Use rConfig CLI commands to test template connectivity:

Terminal window
cd /var/www/html/rconfig8/current
php artisan rconfig:download-device {device-id} --debug

The --debug flag provides verbose output showing:

  • Connection establishment attempts
  • Authentication sequence
  • Prompt recognition
  • Command execution
  • Error messages and timeout events

4. Analyze Results Review command output for:

  • Successful authentication
  • Proper prompt recognition
  • Complete command execution
  • Clean disconnection
  • Any error messages or warnings

5. Refine Template Based on test results, adjust:

  • Prompt recognition patterns
  • Timeout values
  • Command syntax
  • Privilege escalation sequences

6. Iterate Until Successful Repeat the testing cycle until the template reliably connects and retrieves configurations from test devices.

7. Expand Testing Before production deployment:

  • Test with multiple devices of the same type
  • Verify performance with devices in different network locations
  • Confirm reliability over multiple connection cycles

For comprehensive documentation on all available YAML keys, value formats, and configuration options, consult the official template repository documentation:

GitHub Repository: https://github.com/rconfig/rConfig-templates

The repository includes:

  • Complete YAML key reference
  • Parameter descriptions and value formats
  • Vendor-specific configuration examples
  • Template development best practices
  • Community-contributed templates with annotations

Organizations managing diverse network equipment can leverage template strategies to minimize configuration overhead:

Generic Template Approach Create broadly compatible templates that work across multiple vendors with similar CLI behaviors:

  • Start with vendor-neutral prompt patterns
  • Use conservative timeout values
  • Avoid vendor-specific commands unless necessary
  • Test across different manufacturers before deployment

Vendor-Specific Template Library For complex environments, maintain separate templates for each vendor and platform:

  • Precise prompt recognition for each device type
  • Optimized timeout values based on device performance characteristics
  • Vendor-specific command syntax and privilege escalation
  • Custom paging control appropriate for each platform

Implementing consistent naming conventions improves template management and device assignment:

Recommended Patterns

  • Vendor-Platform-Protocol: Cisco-IOSXE-SSH
  • Vendor-Model-Version: Juniper-MX-JunOS15
  • Function-Type: Firewall-Generic-SSH
  • Location-Vendor-Type: DC1-Arista-Leaf

Clear naming enables administrators to quickly identify appropriate templates during device configuration and simplifies template library maintenance.

Template-related issues typically manifest as connection failures, authentication errors, or incomplete configuration retrieval. Systematic troubleshooting identifies root causes and guides resolution.

Symptoms

  • Device connections fail with timeout errors
  • Configuration downloads incomplete
  • Intermittent connection success

Common Causes

  1. Timeout Value Too Low: Device requires more time to respond than template allows
  2. Network Latency: High-latency connections (WAN, VPN) need extended timeouts
  3. Device Performance: Overloaded devices respond slowly to commands
  4. Prompt Pattern Mismatch: rConfig waits indefinitely for prompt that never matches

Resolution Steps

  1. Increase timeout value incrementally (start with 5-second increases)
  2. Test with --debug flag to observe actual response times
  3. Verify prompt patterns match actual device output
  4. Consider network path and adjust timeouts for remote devices
  5. Monitor device CPU/memory utilization during connection attempts

Example Fix

# Original - too aggressive
timeout: 5
# Adjusted for WAN devices
timeout: 20

The most effective troubleshooting tool is debug-enabled connection testing via CLI:

Terminal window
cd /var/www/html/rconfig8/current
php artisan rconfig:download-device {device-id} --debug

Debug output reveals:

  • Exact connection sequence and timing
  • Authentication prompts and responses
  • Command execution and device replies
  • Timeout events and duration
  • Error messages with context
  • Prompt recognition patterns matched

Analyze debug output systematically:

  1. Verify connection establishment
  2. Check authentication prompt recognition
  3. Confirm credential exchange
  4. Observe post-authentication prompt detection
  5. Review command execution sequence
  6. Identify where process fails or hangs

This information directly guides template parameter adjustment.

For complex template issues or unsupported device types:

Community Resources

  • Review GitHub repository for similar device templates
  • Search community forums for related discussions
  • Consult vendor documentation for CLI specifications

Enterprise Support Organizations with rConfig Enterprise support can contact the support team for:

  • Custom template development assistance
  • Complex multi-vendor environment guidance
  • Performance optimization for large-scale deployments
  • Integration with specialized network equipment

Contact: [email protected]

Maintain a Template Library

  • Document all custom templates with creation date and purpose
  • Store templates in version control for change tracking
  • Create templates for new device types before mass deployment
  • Review and update templates quarterly for optimization opportunities

Standardization

  • Use consistent naming conventions across template library
  • Establish organizational standards for timeout values
  • Document vendor-specific requirements and quirks
  • Share successful templates across teams to prevent duplication

Testing Discipline

  • Never deploy untested templates to production devices
  • Maintain test devices representing each major platform
  • Validate templates against multiple devices of same type
  • Test template changes before applying to production fleet

Credential Protection

  • Never embed credentials in template files
  • Use rConfig’s encrypted credential storage
  • Implement role-based access for template modification
  • Audit template changes for security implications

Connection Security

  • Prefer SSH over Telnet whenever supported
  • Use appropriate key exchange and encryption algorithms
  • Consider certificate-based authentication where applicable
  • Document security requirements in template comments

Privilege Management

  • Use minimum required privilege level
  • Enable mode only when necessary for command execution
  • Document privilege escalation requirements
  • Monitor for privilege-related authentication failures

Template Documentation

  • Use YAML comments extensively to explain parameters
  • Document device compatibility and testing history
  • Note any vendor-specific quirks or limitations
  • Include creation date and author information

Organizational Knowledge Base

  • Maintain central documentation for template library
  • Document troubleshooting procedures for common issues
  • Create runbooks for template creation and testing
  • Share lessons learned from template development

Once templates are created and validated, assign them to devices through the device management interface:

  1. Navigate to Devices → Device Management
  2. Select the device to configure (or create new device)
  3. In the device configuration form, select the appropriate template from the Connection Template dropdown
  4. Save the device configuration

The assigned template controls all connection behavior for that device. When rConfig initiates configuration downloads, SNMP operations, or other device interactions, it uses the template parameters to establish and manage the connection.

Multiple devices can share the same template, enabling consistent connection behavior across device fleets. This is particularly valuable when managing large numbers of similar devices or rolling out standardized configurations across infrastructure.

For detailed device management procedures, refer to the Device Management documentation.

Template testing and validation through the command-line interface provides detailed insight into connection behavior. For comprehensive CLI command documentation, including debug flags, output interpretation, and troubleshooting techniques, see the CLI Commands section.

Key commands for template testing:

Terminal window
# Test single device connection with debug output
php artisan rconfig:download-device {device-id} --debug
# Download configuration from device
php artisan rconfig:download-device {device-id}
# Test connectivity without configuration download
php artisan rconfig:test-connection {device-id}

Template configuration integrates with several rConfig V8 features:

Creating New Templates

Troubleshooting Template Issues

ParameterPurposeTypical Values
timeoutConnection timeout in seconds5-30 seconds
usernameUsername prompt pattern”Username:”, “login:“
passwordPassword prompt pattern”Password:”, “password:“
promptCLI ready prompt patternDevice-specific regex
protocolConnection protocolSSH, Telnet
paging_commandDisable output pagingVendor-specific
enable_passwordEnable mode prompt”Password:“
enable_commandPrivilege escalation”enable”, “en”
ScenarioRecommended TimeoutRationale
LAN devices, modern hardware10-15 secondsFast network, responsive devices
WAN devices, remote locations20-30 secondsNetwork latency considerations
Legacy equipment25-35 secondsSlower device processing
Devices with large configs30-45 secondsExtended output generation time
Test/development environment15 secondsBalance speed and reliability

Connection templates provide the foundation for reliable, scalable device connectivity in rConfig V8. By defining connection parameters, authentication patterns, and CLI behaviors in reusable YAML configurations, templates enable consistent communication with diverse network equipment across multi-vendor environments.

Key Takeaways:

  • Templates separate connection logic from device configuration, enabling fleet-scale management
  • YAML-based configuration provides flexibility with human readability
  • One-click repository import provides access to community-contributed templates for dozens of platforms
  • Systematic testing and refinement ensures reliable template performance
  • Proper timeout tuning balances connection reliability with operational efficiency
  • Debug mode connection testing provides detailed insight for troubleshooting
  • Template standardization reduces configuration complexity and improves maintainability

Effective template management—combining proper creation workflows, thorough testing, performance optimization, and ongoing maintenance—ensures rConfig V8 reliably connects to network devices, retrieves configurations, and supports automated network management operations across your infrastructure.

For organizations managing complex multi-vendor environments or requiring assistance with custom template development, rConfig Enterprise support provides expert guidance and assistance. Contact [email protected] for more information.