Code Monkey home page Code Monkey logo

development-starter-kit's Introduction

Development Starter Kit

This is a set of resources you can use to kick-start development, as well as keeping a healthy separation between development resources and production deliverables. You are welcome to clone this and run with it, however I'm mainly sharing this to provide an example of what has worked well for me when trying to keep a tidy and sane development environment.

Galaxy

Nothing in this starter kit is new - it's just bringing together already excellent projects. As such, we'll use ansible-galaxy to pull down the required Ansible roles - use ansible-galaxy install -r requirements.yml -p roles/ --force (or modify this to your requirements) and you'll be ready to run the playbook below. Remember, you can add that line to your Jenkins job when you have it up and running, to make sure third-party changes are automatically applied to your environments (you might, of course, not want to do this after all).

Playbook

The development.yml in this repository runs all development environment-specific configuration. Currently it's configured to create users and add SSH keys, as well as configuring jenkins and gitlab. The beauty of this setup is that with the inventory hierachy (explained below) you only have to run the development playbook once to configure your whole pipeline, while environment-specific playbooks and group_vars still exist on a per-environment basis. Run this playbook referring to the whole inventory directory (-i inventory) to configure the whole pipeline at once.

Inventory

Within the inventory directory exists a subdirectory, per environment, that houses a list of servers (in the inventory file) and a list of environment-specific variables (under the group_vars directory). This gives you a clean separation of environments, as well as a single root you can run pipeline-wide changes to (adding users, changing repositories, etc - things that wouldn't be done in production). The inventory should be referred to, when running environment-specific plays, at the directory level (eg -i inventory/sandbox) to capture that environment's group_vars in the play.

Vagrant

This is an example Vagrantfile, using the yaml plugin and vagrant/config.yaml to stand up some example servers and run Ansible against them. Groups and group_vars are configured in the Vagrantfile.

myrepos

MyRepos is an excellent tool for developers, since it easily makes sure they're looking at the latest changes (and the correct branch) for all the repositories on a project. You can configure the repositories to pull in the .mrconfig file - some examples are there for you to modify.

Upon installing the myrepos tool (brew install mr on a mac), running mr co while in the root of this repository will clone all development repos to the repos directory. The tool also allows you to update all repos on the fly as well as many other useful features - man mr for more details.

development-starter-kit's People

Contributors

jamesbelchamber avatar

Stargazers

skultek avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.