• Stars
    star
    198
  • Rank 196,898 (Top 4 %)
  • Language
    Groovy
  • License
    MIT License
  • Created almost 7 years ago
  • Updated almost 4 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Wolox CI

This a Jenkins library built to make it easier for us at Wolox to configure pipelines without necessarily knowing about Jenkinsfile syntax. All our projects are built using a Dockerfile

When using this library, your Jenkinsfile should look something like this:

@Library('wolox-ci') _

node {

  checkout scm

  woloxCi('.woloxci/config.yml');
}

It basically loads the library, clones the target repository and calls woloxCi to make its magic. As an argument, woloxCi receives the path to a configuration yaml file. This file looks something like this:

config:
  dockerfile: .woloxci/Dockerfile
  project_name: some-rails-project

services:
  - mssql

steps:
  analysis:
    - bundle exec rubocop -R app spec --format simple
    - bundle exec rubycritic --path ./analysis --minimum-score 80 --no-browser
  setup_db:
    - bundle exec rails db:create
    - bundle exec rails db:schema:load
  test:
    - bundle exec rspec
  security:
    - bundle exec brakeman --exit-on-error
  audit:
    - bundle audit check --update


environment:
  RAILS_ENV: test
  GIT_COMMITTER_NAME: a
  GIT_COMMITTER_EMAIL: b
  LANG: C.UTF-8

jenkinsEnvironment:
  - JENKINS_URL

timeout: 600

This file has different sections:

Configuration

The section under the config label defines some basic configuration for this project:

  1. The dockerfile that contains the image for the project to run.
  2. The project name.

Services

This section lists the project's dependencies. Each section will define and expose some environment variables that might be needed by the application:

Microsoft SQL

When listing mssql as a service, this will build a docker image from microsoft/mssql-server-linux exposing the following environment variables:

  1. DB_USERNAME
  2. DB_PASSWORD
  3. DB_HOST
  4. DB_PORT

PostgreSQL

When listing postgres as a service, this will build a docker image from postgres exposing the following environment variables:

  1. DB_USERNAME
  2. DB_PASSWORD
  3. DB_HOST
  4. DB_PORT

Redis

When listing redis as a service, this will build a docker image from redis exposing the following environment variables:

  1. REDIS_URL: the redis url that looks like this redis://redis

MySQL

When listing mysql as a service, this will build a docker image from mysql exposing the following environment variables:

  1. DB_USERNAME
  2. DB_PASSWORD
  3. DB_HOST
  4. DB_PORT

MongoDB

When listing mongo as a service, this will build a docker image from mongo exposing the following environment variables:

  1. DB_USERNAME
  2. DB_PASSWORD
  3. DB_HOST
  4. DB_PORT

Elasticsearch

When listing elasticsearch:6.4.0 as a service (it's mandatory specify the image version), this will build a docker image from elasticsearch exposing the following environment variables:

  1. ELASTICSEARCH_URL

Steps

This section lets you define the steps you need to build your project. Each level inside the steps section is a stage in the Jenkins pipeline and each item in the stage is a command to run. In the case above, there are 5 stages named:

  1. analysis
  2. setup_db
  3. test
  4. security
  5. audit

The analysis stage, for example, runs the following commands:

  1. bundle exec rubocop -R app spec --format simple
  2. bundle exec rubycritic --path ./analysis --minimum-score 80 --no-browser

Environment

This section lets you set up custom environment variables. Each item inside this section defines a variable with its value.

Jenkins Environment

This section lets you define what Jenkins environment values you want to pass to the docker image, i.e. JENKINS_URL. Bear in mind that, for convenience, Wolox CI already passes the following Jenkins Environment Variables to the Docker image by default:

  1. BUILD_ID
  2. BRANCH_NAME
  3. CHANGE_ID
  4. CHANGE_BRANCH (if job is PR-triggered)
  5. CHANGE_TARGET (if job is PR-triggered)

Timeout

This section lets you set up a custom timeout in seconds. The default is 600 (10 minutes).

More Repositories

1

react-chat-widget

Awesome chat widget for your React App
TypeScript
1,447
star
2

carthage_cache

A tool that allows to cache Carthage/Build folder in Amazon S3.
Ruby
174
star
3

tech-guides

Guides and standards for the techs we love using at Wolox
Shell
156
star
4

express-js-bootstrap

Kickoff for ExpressJS applications.
JavaScript
77
star
5

redux-recompose

A Redux utility belt for reducers and actions. Inspired by acdlite/recompose.
JavaScript
70
star
6

wor-authentication

Gem to add authentication to your application using JWT, with expirable, renewable and customizable tokens!
Ruby
62
star
7

async-requests

Ruby
57
star
8

ReactiveArray

An array class implemented in Swift that can be observed using ReactiveCocoa's Signals
Swift
53
star
9

dictum

Create automatic documentation of your Rails API endpoints through your tests
Ruby
53
star
10

firestore-service

JavaScript
28
star
11

ios-style-guide

Wolox's iOS style guide
26
star
12

WLXBluetoothDevice

A block-based wrapper of CoreBluetooth
Objective-C
26
star
13

frontend-bootstrap

JavaScript
24
star
14

react-bootstrap

JavaScript
23
star
15

dictum.js

Create automatic documentation of your NodeJS API endpoints
JavaScript
23
star
16

wor-paginate

Ruby
22
star
17

wolmo-bootstrap-react-native

Bootstrap generator for React Native projects
JavaScript
20
star
18

wolmo-core-ios

Wolmo - Wolox Mobile SDK core library for iOS
Swift
17
star
19

wor-push-notifications-aws

Ruby
16
star
20

wor-prof

Wor-prof (Wprof) is a gem for Ruby On Rails which its only purpose is to measure a RoR app's performance through a profile with different times of response.
Ruby
15
star
21

arg-localities

Get localities by province for Argentina
Shell
13
star
22

wor-requests

Make external requests in you service objects, with easy logging and error handling!
Ruby
12
star
23

aws-deploy-script-frontend

JavaScript
12
star
24

rails-bootstrap

A Ruby on Rails base project with Wolox standard defaults
Ruby
11
star
25

frontend-cookbook

Reusable components and features design and created by Wolox
TypeScript
11
star
26

wolmo-cookbook-android

Wolmo Cookbook - Recipes for common cases done with Wolmo
Kotlin
9
star
27

fictium

A gem with the power to generate documentation from your tests
Ruby
9
star
28

WLXWebViewReloader

An extension to WKWebView that reloads the web view when the source changes.
Objective-C
8
star
29

react-native-renavigate

React native navigation made easy using redux 💫
JavaScript
8
star
30

codestats

Self-hosted open source app to control metrics of your code
Ruby
7
star
31

terraform-base-infra

HCL
7
star
32

wolmo-core-android

Wolmo Core - Wolox Mobile SDK core module for Android
Kotlin
7
star
33

express-wolox-logger

JavaScript
6
star
34

netcore-bootstrap

Kickoff for NetCore applications using EntityFramework.
C#
6
star
35

node-typescript-bootstrap

TypeScript
6
star
36

ios-base-project

A base iOS project with all the minimum dependencies already configured.
Swift
6
star
37

project-health-checker

JavaScript
5
star
38

assigner

A script to pick a random reviewer and assign it to a pull request
Ruby
5
star
39

equalizer

CSS
5
star
40

wor-batchifier

Ruby
5
star
41

angular-bootstrap

TypeScript
4
star
42

wolmo-reactive-core-ios

Swift
4
star
43

warp

WARP - Seamless mobile assets management
Python
4
star
44

eslint-config-wolox-node

JavaScript
4
star
45

eslint-config-wolox-react

JavaScript
3
star
46

cookbook-ios

Swift
3
star
47

cypress-bootstrap

TypeScript
3
star
48

eslint-config-wolox

Wolox eslint standard
JavaScript
3
star
49

wolmo-networking-android

Wolmo Networking - Wolox Mobile SDK networking module for Android
Java
3
star
50

collection-view-example

An iOS project that shows how to use UICollectionView to make re-utilizable components. It also shows how to structure an app using the MVVM pattern.
Objective-C
2
star
51

java-bootstrap

Java
2
star
52

wolmo-testing-android

Kotlin
2
star
53

elasticsearch-rails-demo

Ruby
2
star
54

automation-test-angular

TypeScript
2
star
55

aws-lambdas-bootstrap

JavaScript
2
star
56

WoloxAndroidBootstrap

Wolox's base template for new Android projects.
Kotlin
2
star
57

android-bootstrap-mvvm

Kotlin
2
star
58

wolmo-maps-android

Wolmo Maps - Wolox Mobile SDK maps module for Android
Java
2
star
59

github-organization-manager-react

CSS
2
star
60

simple-crud

Ruby
2
star
61

fastlane-mobile

Ruby
2
star
62

wdio-appium-bootstrap

JavaScript
2
star
63

node-graphql-bootstrap

JavaScript
2
star
64

localization-culture-core

This project allows localization for NetCore using .json files instead of .resx.
C#
2
star
65

silk-paper-node

JavaScript
1
star
66

jira-training-cloner-rails

Ruby
1
star
67

java-meetup-2019

Java
1
star
68

react-app-rewire-wolox

JavaScript
1
star
69

react-conduit

Ruby
1
star
70

angularjs-bootstrap

JavaScript
1
star
71

graphql-inspector-wolox-node

JavaScript
1
star
72

eslint-config-wolox-react-native

JavaScript
1
star
73

layout

SCSS
1
star
74

github-organization-manager

project to manage github repos
JavaScript
1
star
75

infrastructure-provisioning

HTML
1
star
76

angular-conduit

TypeScript
1
star
77

wolox-frontend-templates

HTML
1
star
78

github-organization-manager-node

JavaScript
1
star
79

express-wolox-schema-validator-node

JavaScript
1
star
80

python-bootstrap

1
star