Forge Home

fact_geoip

Custom Facts that return the geograpical and ip address of the puppet agents internet egress point

9,499 downloads

9,327 latest version

4.6 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Support the Puppet Community by contributing to this module

You are welcome to contribute to this module by suggesting new features, currency updates, or fixes. Every contribution is valuable to help ensure that the module remains compatible with the latest Puppet versions and continues to meet community needs. Complete the following steps:

  1. Review the module’s contribution guidelines and any licenses. Ensure that your planned contribution aligns with the author’s standards and any legal requirements.
  2. Fork the repository on GitHub, make changes on a branch of your fork, and submit a pull request. The pull request must clearly document your proposed change.

For questions about updating the module, contact the module’s author.

Version information

  • 0.1.1 (latest)
  • 0.1.0
released Feb 27th 2015
This version is compatible with:
  • , ,

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'vormetriclabs-fact_geoip', '0.1.1'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add vormetriclabs-fact_geoip
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install vormetriclabs-fact_geoip --version 0.1.1

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

vormetriclabs/fact_geoip — version 0.1.1 Feb 27th 2015

fact_geoip

Table of Contents

  1. Overview
  2. Module Description - What the module does and why it is useful
  3. Setup - The basics of getting started with fact_geoip
  4. Reference - An under-the-hood peek at what the module is doing and how
  5. Limitations - OS compatibility, etc.
  6. Development - Guide for contributing to the module

Overview

This module is a custom fact that returns the geographical information and ip address of the agents edge ip address to the internet.

This can be very useful if you are using puppet with roaming devices(laptops, failover vms, etc...)

Module Description

Ever want to know where a puppet agent "Actually" is? Maybe you are managing a fleet of laptops for a sales force, and want to track location of it's internet connection? Or how about applying the timezone for a server based on it's internet egress point, without any hardcoding?

This module utilizes 2 cloud based services, ipify, and freegeoip, to get the internet egress point IP address(edge router), and it's geolocation information.

Setup

What fact_geoip affects

  • Nothing

Beginning with fact_geoip

Just install the module

puppet module install vormetriclabs/fact_geoip

Reference

The list of facts returned about the location of the devices internet egress point.

  • geoip_city => Mountain View
  • geoip_country_code => US
  • geoip_country_name => United States
  • geoip_ipaddress => 8.8.8.8
  • geoip_latitude => 37.386
  • geoip_longitude => -122.084
  • geoip_metro_code => 807
  • geoip_region_code => CA
  • geoip_region_name => California
  • geoip_time_zone => America/Los_Angeles

Limitations

Anything that supports Ruby net/http

Development

Feel free to fork, code up, and pull request.