Skip to content

Instantly share code, notes, and snippets.

@rajendraprasad9
rajendraprasad9 / Jenkinsfile
Created June 22, 2022 09:26 — forked from merikan/Jenkinsfile
Some Jenkinsfile examples
Some Jenkinsfile examples
@rajendraprasad9
rajendraprasad9 / Jenkinsfile
Created December 24, 2020 10:01 — forked from jonico/Jenkinsfile
Example for a full blown Jenkins pipeline script with multiple stages, kubernetes templates, shared volumes, input steps, injected credentials, heroku deploy, sonarqube and artifactory integration, Docker containers, multiple Git commit statuses, PR merge vs branch build detection, REST API calls to GitHub deployment API, stage timeouts, stage c…
#!groovy
import groovy.json.JsonOutput
import groovy.json.JsonSlurper
def label = "mypod-${UUID.randomUUID().toString()}"
podTemplate(label: label, yaml: """
spec:
containers:
- name: mvn
image: maven:3.3.9-jdk-8-alpine
@rajendraprasad9
rajendraprasad9 / Jenkinsfile
Created December 23, 2020 15:20 — forked from gazoakley/Jenkinsfile
Jenkinsfile for running Terraform
pipeline {
agent any
parameters {
string(name: 'environment', defaultValue: 'default', description: 'Workspace/environment file to use for deployment')
string(name: 'version', defaultValue: '', description: 'Version variable to pass to Terraform')
booleanParam(name: 'autoApprove', defaultValue: false, description: 'Automatically run apply after generating plan?')
}
environment {
@rajendraprasad9
rajendraprasad9 / merge
Created September 10, 2020 13:24 — forked from tmiller/merge
Bash script to merge master into all branches
#!/bin/bash
# Merges the master branch into all other branches
#
# Process:
#
# - Save the name of the current branch
# - If the current branch is not master then checkout master.
# - Pull the latest changes for master from its upstream branch.
# - Loop over each local branch.
@rajendraprasad9
rajendraprasad9 / manage.sh
Created June 3, 2020 15:34 — forked from WhiteBlue/manage.sh
a script install kubernetes master & node on CentOS7
#!/bin/bash
set -e
reset=$(tput sgr0)
green=$(tput setaf 76)
blue=$(tput setaf 25)
red=$(tput setaf 1)
info() {
# coding=utf-8
import copy
op_method = ['+', '-', '*', '/']
def copy_arr(old, e):
new_buf = copy.copy(old)
new_buf.append(e)
return new_buf
@rajendraprasad9
rajendraprasad9 / build-llvm.bash
Created June 3, 2020 15:33 — forked from WhiteBlue/build-llvm.bash
Build llvm for OS X
#!/bin/bash
set -e
# Building LLVM on OSX CMake setup script
#
# Required:
# - clang by Xcode6 or later
# - cmake
# - ninja
#