Skip to content

Instantly share code, notes, and snippets.

View rasheedamir's full-sized avatar

Rasheed Amir rasheedamir

View GitHub Profile
@rasheedamir
rasheedamir / failing-jenkins-slave.md
Last active September 29, 2017 09:10
failing jenkins slave
Started by user [email protected]
Obtained Jenkinsfile from git http://gitea/dd/systemtest.git
Loading library github.com/stakater/fabric8-pipeline-library@master
 > git rev-parse --is-inside-work-tree # timeout=10
Setting origin to https://github.com/stakater/fabric8-pipeline-library.git
 > git config remote.origin.url https://github.com/stakater/fabric8-pipeline-library.git # timeout=10
Fetching origin...
Fetching upstream changes from origin
 > git --version # timeout=10
# "ps" "-o" "pid=" "9999"
printf "EXITCODE %3d" $?; exit
# EXITCODE   1# "ps" "-o" "pid=" "23"
printf "EXITCODE %3d" $?; exit
    23
# EXITCODE   0# "ps" "-o" "pid=" "9999"
printf "EXITCODE %3d" $?; exit
# EXITCODE   1# "ps" "-o" "pid=" "23"
printf "EXITCODE %3d" $?; exit
Started by user [email protected]
Obtained Jenkinsfile from git http://gitea/digitaldealer/systemtest
Loading library github.com/stakater/fabric8-pipeline-library@master
 > git rev-parse --is-inside-work-tree # timeout=10
Setting origin to https://github.com/stakater/fabric8-pipeline-library.git
 > git config remote.origin.url https://github.com/stakater/fabric8-pipeline-library.git # timeout=10
Fetching origin...
Fetching upstream changes from origin
 > git --version # timeout=10
@rasheedamir
rasheedamir / openshiftsync-error.md
Created September 26, 2017 05:22
openshiftsync error
Sep 26, 2017 5:18:22 AM io.fabric8.jenkins.openshiftsync.BuildSyncRunListener onCompleted
INFO: onCompleted job/systemtest/300/
Sep 26, 2017 5:18:22 AM hudson.model.listeners.RunListener report
WARNING: RunListener failed
java.lang.NullPointerException
	at io.fabric8.jenkins.openshiftsync.JenkinsUtils.maybeScheduleNext(JenkinsUtils.java:312)
	at io.fabric8.jenkins.openshiftsync.BuildSyncRunListener.onCompleted(BuildSyncRunListener.java:170)
	at hudson.model.listeners.RunListener.fireCompleted(RunListener.java:211)
	at org.jenkinsci.plugins.workflow.job.WorkflowRun.finish(WorkflowRun.java:664)
@rasheedamir
rasheedamir / App.java
Created August 23, 2017 05:35 — forked from thomasdarimont/App.java
Example for using the keycloak Spring Security Adapter (2.4.0.Final) with a Bearer-only Spring Boot App deployed in JBoss EAP
package de.tdlabs.examples;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.support.SpringBootServletInitializer;
@SpringBootApplication
public class App extends SpringBootServletInitializer {
@rasheedamir
rasheedamir / gist:9d801e29fa5e6128883cbaf24c832984
Created August 22, 2017 19:01 — forked from mdisec/gist:b0d44cc14e4c4c10cd64
Kibana with Nginx Reverse Proxy + SSL + HTTP Auth
# Nginx proxy for Elasticsearch + Kibana
#
# In this setup, we are password protecting the saving of dashboards. You may
# wish to extend the password protection to all paths.
#
# Even though these paths are being called as the result of an ajax request, the
# browser will prompt for a username/password on the first request
#
# If you use this, you'll want to point config.js at http://FQDN:443/ instead of
# http://FQDN:9200
@rasheedamir
rasheedamir / gist:d3b60d7d7a65693eabc7928d82d77ece
Created July 31, 2017 11:30
fabric8-springboot-jenkinsfile.md
#!/usr/bin/groovy
@Library('github.com/fabric8io/[email protected]')
def localItestPattern = ""
try {
localItestPattern = ITEST_PATTERN
} catch (Throwable e) {
localItestPattern = "*IT"
}
@rasheedamir
rasheedamir / remote-ssh-kube-commands.sh
Created July 26, 2017 10:13 — forked from cmcconnell1/remote-ssh-kube-commands.sh
Run remote command_list on all of the specified kubernetes clusters in AWS EC2: controllers, etcd, or workers
#!/usr/bin/env bash
#
# Author: Chris McConnell
#
# Summary:
# Run remote command_list on all of the specified kubernetes clusters: controllers, etcd, or workers.
#
# Why:
# We have kubernetes and want to run CM jobs / commands on the kube nodes, but CoreOS doesnt have python etc. on it so we can't use CM tools here unless we hack 'em up (which shouldn't), so shell always works.
# Plan to continue to build tools on this and we can take output of this script and slurp up into database, feed to graylog, etc.
@rasheedamir
rasheedamir / troubleshooting.md
Last active March 10, 2020 09:21
troubleshooting collection
FILE # 1

#!groovy

String GIT_VERSION

node {

  def buildEnv
kubectl describe pod jenkins-56914896-826p6
Name:           jenkins-56914896-826p6
Namespace:      default
Node:           /
Labels:         group=io.fabric8.devops.apps
               pod-template-hash=56914896
               project=jenkins
               provider=fabric8
               version=2.2.311