Forge Home

workstation

Puppet module for managing a workstation with yaml

11,122 downloads

4,665 latest version

5.0 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.

Version information

  • 0.1.72 (latest)
  • 0.1.71
  • 0.1.70
  • 0.1.69
  • 0.1.68
  • 0.1.67
  • 0.1.65
  • 0.1.64
  • 0.1.63
  • 0.1.62
  • 0.1.61
  • 0.1.60
  • 0.1.59
  • 0.1.58
  • 0.1.55
  • 0.1.54
  • 0.1.53
  • 0.1.52
  • 0.1.49
  • 0.1.48
  • 0.1.45
  • 0.1.44
  • 0.1.43
  • 0.1.41
  • 0.1.40
  • 0.1.39
  • 0.1.38
  • 0.1.37
  • 0.1.36
  • 0.1.35
  • 0.1.34
  • 0.1.33
  • 0.1.32
  • 0.1.31
  • 0.1.30
  • 0.1.29
  • 0.1.28
  • 0.1.27
  • 0.1.25
  • 0.1.24
  • 0.1.23
  • 0.1.22
  • 0.1.21
  • 0.1.20
  • 0.1.19
  • 0.1.18
  • 0.1.17
  • 0.1.16
  • 0.1.15
  • 0.1.14
  • 0.1.13
  • 0.1.12
  • 0.1.11
  • 0.1.2
  • 0.1.1
  • 0.1.0
released Jan 6th 2019
This version is compatible with:
  • Puppet Enterprise 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x, 2017.3.x, 2017.2.x, 2017.1.x, 2016.5.x, 2016.4.x
  • Puppet >= 4.7.0 < 7.0.0
  • , ,

Start using this module

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

Add this module to your Puppetfile:

mod 'call-workstation', '0.1.72'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add call-workstation
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install call-workstation --version 0.1.72

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

call/workstation — version 0.1.72 Jan 6th 2019

workstation

This module is under active development and should not be considered production-ready at this time.

Table of Contents

  1. Description
  2. Setup - The basics of getting started with workstation
  3. Usage - Configuration options and additional functionality
  4. Limitations - OS compatibility, etc.
  5. Development - Guide for contributing to the module

Description

The workstation module manages tools and config for developer workstations, allowing developers to define, share, and combine workstation configurations in Hiera yaml.

This module is designed to provide a simple way to bootstrap a workstation with developer config. No prior experience with Puppet should be needed to use this module, only a working understanding of YAML. The workstation module is intended to be used via a puppet apply one-liner. However, this module can also be used in a master-agent setup, given an appropriate Hiera hierachy and hieradata in the control repo.

Currently this module only supports macOS, but Linux support will be added soon.

Setup

What workstation affects

This module manages settings for developer workstations. Initially it is focused on ensuring package installation, tool version installation, and dotfile configuration.

Current features:

  • macOS Command Line Tools installation
  • macOS package installation via brew, with full tap/cask support
  • macOS tool version management via asdf (should also support Linux, currently untested)
  • Basic macOS and Linux primary user shell configuration
  • Basic macOS and Linux primary user dotfile management

Setup Requirements

Puppet installed locally via puppet-agent package or puppet gem.

Beginning with workstation

1) Ensure Puppet is installed. If you don't already have the Puppet Agent package installed, the easiest way to get Puppet is sudo gem install puppet --no-ri --no-doc.

2) Install this module locally, as root: sudo puppet module install call-workstation

3) Run puppet apply by copy-pasting one of the example one-liners below, depending on your shell. This will apply the configuration to the current user. Without additional hieradata, only the most basic user configuration will be applied (user shell, default packages).

Bash:

sudo puppet apply -e "class {'workstation': user => $(whoami)}"

Zsh:

sudo puppet apply -e "class {'workstation': user => $(whoami), shell => 'zsh'}"

Fish:

sudo puppet apply -e "class {'workstation': user => "(whoami)", shell => 'fish'}"

4) To supply your own config data, use the --hiera_config flag to point to your custom hiera.yaml. See the 'Usage' section for more details. For example, for bash shell the command will look something like:

sudo puppet apply -e "class {'workstation': user => $(whoami)}" --hiera_config /path/to/workstation-hieradata/hiera.yaml

Be sure to replace /path/to/workstation-hieradata with the real path to your Hiera directory that contains a hiera.yaml config file.

Usage

In order to take full advantage of this module, you'll want to create a repository with your custom configuration data. To get started quickly, you can fork and modify the example at call/workstation-hieradata.

Importantly, in the call/workstation-hieradata example, data/common.yaml contains settings to perform deep merges on package lookups, combined with a glob (*) for the lookup path. This pattern allows you to provide multiple yaml files in a single directory, which may have some overlapping package configuration, while avoiding the problem of duplicate resource declaration in Puppet. You may find it useful to provide a yaml file per application, per team, or based on some other grouping that requires a specific set of config.

Hiera directory structure and lookup behavior is highly configurable. See the Puppet docs on hiera.yaml to learn more.

Limitations

This module currently only supports macOS. Support will be expanded to Linux workstations in the near future.

Development

Fork, improve, and PR!