GithubHelp home page GithubHelp logo

derbluemel / jenkins-puppet-scripts Goto Github PK

View Code? Open in Web Editor NEW

This project forked from vstone/jenkins-puppet-scripts

0.0 2.0 0.0 103 KB

Some scripts to do various checks, mainly for jenkins use.

jenkins-puppet-scripts's Introduction

Introduction

This repo contains various scripts that get used throughout our Jenkins setup.

Usage

A recommended way of using these scripts could be to setup a separate Jenkins job that pull in this repository.

Define each script as a managed script and add the arguments. See the README or script itself to find out what arguments are available.

Jenkins

Below follows a quick overview on how these scripts are used on our Jenkins instance. You can either use the script directly or used it through the config file provider plugin (see below). Both should be pretty straightforward. We use parameters extensively.

Used plugins

The following plugins (and their dependencies) are used for setting up the jobs.

Pipelines

We use 2 almost similar pipelines. One for release branch and one for development branches. The packaging system uses this information to build 2 kind of packages. In short: The release branch needs a tag. The tag will be used as the environment. For development branches. the development name is used as the environment. If a tag is set on such a branch, we will append it to the environment name.

1. Release Pipeline [puppet-tree-release]

Holds ALL the parameters that can influence a build. We use this as a single entry point for our pipeline. You really don't want to start any build except the entry build.

This has a couple of advantages. It will catch problems with your VCS. GIT in our case. If you git submodules, somebody will forget to push the submodule before the parent tree and your job will get stuck in a fail loop. We would not want these kind of hiccups to mess up the build trend for various more important checks.

This job will trigger the next one if everything goes fine.

2. Syntax Checks [puppet-tree-release-syntax]

Do syntax checks on as much code as possible. Currently, we have ruby templates and puppet manifests covered.

0. Add your fantastic spec test script here!

3. Style Checks [puppet-tree-release-style]

The tagging check would be a lot faster to do here, but it might be interesting to already get a picture of the errors on the master branch. :)

4. GIT Tagging check [puppet-tree-release-tagging]

Check if a tag is set. We need to enforce this because otherwise people push stuff into production like savages. We need to get rid of that mentality. If you broke something, create a hotfix with proper tagging etc etc.

5. Packaging [puppet-tree-release-packaging]

Package it. We use fpm to produce RPMs. Easily adjustable to produce debs or ...

6. Deploy it [puppet-tree-release-deploy]

Either push it to a pulp repo, or scp it to some site or ...

TODO:

What we still need is

  • A job for documentation. I have some stuff somewhere.
  • A job for spec tests. Preferably, also a Jenkins warnings parser addition to parse the output.
  • While we are talking about Jenkins warnings parser: We need to support having modules in different structures than just /modules/ALLTHESTUFF.

jenkins-puppet-scripts's People

Contributors

vstone avatar krisbuytaert 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.