This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [1] pry(main)> load "validation_demo.rb" | |
| => true | |
| [2] pry(main)> # The finance method | |
| [3] pry(main)> he = HashExample.new | |
| => #<HashExample:0x0000564aaaebc558> | |
| [4] pry(main)> he.check(true) | |
| Airhorn would say All conditions are true! | |
| => true | |
| [5] pry(main)> he.check(false) | |
| Airhorn would say Something failed! I don't know what! Figure it out! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| apiVersion: extensions/v1beta1 | |
| kind: Deployment | |
| metadata: | |
| name: {{ template "cds.fullname" . }}-api | |
| labels: | |
| app: {{ template "cds.fullname" . }}-api | |
| chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" | |
| release: "{{ .Release.Name }}" | |
| heritage: "{{ .Release.Service }}" | |
| spec: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| withEnv(build_env()) { | |
| nexusArtifactUploader artifactId: 'client', classifier: 'linux', credentialsId: '', file: env.ARTIFACT, groupId: 'example', nexusPassword: '', nexusUrl: 'example:8081/nexus', nexusUser: 'deployment', packaging: 'tar.bz2', protocol: 'http', repository: env.REPO, type: '', version: env.JVERSION | |
| } | |
| def build_env() { | |
| def env_filename = env.BUILD_TAG + '.build.env' | |
| sh './buildenv.sh > /tmp/${BUILD_TAG}.build.env' | |
| def prop_list = readFile('/tmp/' + env_filename).split('\n') | |
| return prop_list | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from jenkins import Jenkins | |
| from ConfigParser import RawConfigParser | |
| import requests | |
| import json | |
| # read from /etc/jenkins_jobs/jenkins_jobs.ini | |
| cfg = RawConfigParser() | |
| cfg.read('/etc/jenkins_jobs/jenkins_jobs.ini') | |
| args = dict(cfg.items('jenkins')) | |
| args['username'] = args.pop('user') |