View jenkins-proxy.logs
{"component":"proxy","header":"-H Accept-Encoding: gzip, deflate, br -H Accept-Language: en-US,en;q=0.9 -H Accept: text/css,*/*;q=0.1 -H Connection: close -H Cookie: JSESSIONID.a6d67309=node04ioxlpt3kfggc8m9r8z0llf049.node0; 0d48feff5bad313069a8838ba4e06eb7=abefd952584a18a7f0a33974601d16df -H Forwarded: for=125.16.100.118;host=jenkins.prod-preview.openshift.io;proto=https -H Referer: https://jenkins.prod-preview.openshift.io/ -H User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36 -H X-Forwarded-For: 125.16.100.118 -H X-Forwarded-Host: jenkins.prod-preview.openshift.io -H X-Forwarded-Port: 443 -H X-Forwarded-Proto: https","level":"info","msg":"Handling incoming proxy request.","request":"GET /static/96364e59/css/layout-common.css","request-hash":2609670898,"time":"2018-05-03T07:51:29Z","type":"Jenkins UI"}
{"component":"proxy","level":"info","msg":"Found cookie node04ioxlpt3kfggc8m9r8z0llf049.node0","ns":"ksagathi-preview-jenkins","request-hash
View testScenario1.sh
#!/bin/sh
# Run Idler locally and then this script can be run
UnIdleTest()
{
curl -X GET 'http://localhost:8080/api/idler/unidle/ksagathi-preview-jenkins?openshift_api_url=https://api.starter-us-east-2a.openshift.com/'
sleep 5m
isIdle=`curl -X GET 'http://localhost:8080/api/idler/isidle/ksagathi-preview-jenkins?openshift_api_url=https://api.starter-us-east-2a.openshift.com/'|jq .is_idle`
if [ $isIdle == 'true' ]
then
View loadTestingGithubWH.sh
#!/bin/sh
curl 'https://jenkins.prod-preview.openshift.io/github-webhook/' -X POST -H 'Content-Type: application/json' -H 'User-Agent: GitHub-Hookshot/0368bb5' -H 'X-GitHub-Delivery: 5ff19448-3c88-11e8-923c-f0d642a8d6a5' -H 'X-GitHub-Event: push' -H 'X-Hub-Signature: sha1=e184070cfd3d3a22a6875280e4defe0e3a5b10c0' -d '{ "ref": "refs/heads/master", "before": "5462f5117951faf8f1cc8a379ed5668b02447275", "after": "b7125a147c5818288ad173a0af6ba8fc2ef593a1", "created": false, "deleted": false, "forced": false, "base_ref": null, "compare": "https://github.com/kishansagathiya/sample1/compare/5462f5117951...b7125a147c58", "commits": [ { "id": "b7125a147c5818288ad173a0af6ba8fc2ef593a1", "tree_id": "8d36d83dcec441314f850c0a47c1af98cd938dc9", "distinct": true, "message": "Update README.adoc", "timestamp": "2018-04-10T11:58:24+05:30", "url": "https://github.com/kishansagathiya/sample1/commit/b7125a147c5818288ad173a0af6ba8fc2ef593a1", "author": { "name": "Kishan Sagathiya", "email": "kishansagathiya@gmail.com", "username":
View auth_endpoints
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Login ctrl=Login route="GET /api/login"
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Authorize ctrl=Authorize route="GET /api/authorize"
time="2018-01-11 20:31:33" level=info msg=mount action=Callback ctrl=Authorize route="GET /api/authorize/callback"
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Logout ctrl=Logout route="GET /api/logout"
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Delete ctrl=Token route="DELETE /api/token" security=jwt
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Exchange ctrl=Token route="POST /api/token"
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Retrieve ctrl=Token route="GET /api/token" security=jwt
20:31:33 app | time="2018-01-11 20:31:33" level=info msg=mount action=Callback ctrl=Token route="GET /api/token/link/callback"
20:31:
View gist:9164e98a28bdea5037c30400dad32296
15:28:02 app | time="2017-12-26 15:28:02" level=info msg="request started" PATCH="/api/users" action=update ctrl=UsersController from="::1" pkg=log.LogRequest.func1 req_id=PtfLVyff8X-5
15:28:02 app | time="2017-12-26 15:28:02" level=info msg="request headers" Accept=[*/*] Authorization=[bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJiTnEtQkNPUjNldi1FNmJ1R1NhUHJVLTBTWFg4d2hoRGxtWjZnZWVua1RFIn0.eyJqdGkiOiI0MGQ4ODU0OC1iMWQxLTQ1ODItYTg0My0wMTk5NmI5ZjFiODkiLCJleHAiOjE1MTY4NzQyMTIsIm5iZiI6MCwiaWF0IjoxNTE0MjgyMjEyLCJpc3MiOiJodHRwczovL3Nzby5wcm9kLXByZXZpZXcub3BlbnNoaWZ0LmlvL2F1dGgvcmVhbG1zL2ZhYnJpYzgtdGVzdCIsImF1ZCI6ImZhYnJpYzgtb25saW5lLXBsYXRmb3JtIiwic3ViIjoiYzgxOGNiOTYtMjExYi00MTk3LThkM2YtMjVjNzJhYWRhMDRkIiwidHlwIjoiQmVhcmVyIiwiYXpwIjoiZmFicmljOC1vbmxpbmUtcGxhdGZvcm0iLCJhdXRoX3RpbWUiOjE1MTQyNzY5MzcsInNlc3Npb25fc3RhdGUiOiJjMmYxNDM2Ni1lZjc3LTRhZjgtYmMxMS0wNmFkZjY2YTY4ZjkiLCJhY3IiOiIwIiwiYWxsb3dlZC1vcmlnaW5zIjpbImh0dHBzOi8vcHJvZC1wcmV2aWV3Lm9wZW5zaGlmdC5pbyIsImh0dHBzOi8vYXV0aC5wcm9kLXByZXZ
View error
15:50:21 app | time="2017-11-28 15:50:21" level=info msg="request started" POST="/api/token" action=Exchange ctrl=token from="::1" pkg=log.LogRequest.func1 req_id=8xORjvjQDW-6
15:50:21 app | time="2017-11-28 15:50:21" level=info msg="request headers" Accept=[*/*] Content-Length=[284] Content-Type=[application/json] User-Agent=[curl/7.51.0] pkg=log.LogRequest.func1 req_id=8xORjvjQDW-6
15:50:21 app | time="2017-11-28 15:50:21" level=info msg=payload pkg=log.LogRequest.func1 raw="{\"client_id\":\"5dec5fdb-09e3-4453-b73f-5c828832b28e\",\"client_secret\":\"witsecret\",\"code\":\"uss.xkn7PJ2F-nrhzef79g2HzbphGow6xMy5_A2eq-egKbs.fd162ea9-f6cb-441d-a8f4-dc16509136c9.239ed057-eec1-425b-a7eb-f4b338c94cdd\",\"grant_type\":\"authorization_code\",\"redirect_uri\":\"http://quora.com\"}" req_id=8xORjvjQDW-6
15:50:21 app | time="2017-11-28 15:50:21" level=info msg="request started" POST="/api/token" action=Exchange ctrl=token from="::1" pkg=log.LogRequest.func1 req_id=8xORjvjQDW-6
15:50:21
View OSIO login workflow
Login Flow
---------------------------------------------------------------------------------------------
1. http://localhost:8089/api/login
2. Sends a request to keycloak( which is provider here).
https://sso.prod-preview.openshift.io/auth/realms/fabric8-test/protocol/openid-connect/auth?access_type=online&client_id=fabric8-online-platform&redirect_uri=http%3A%2F%2Flocalhost%3A8089%2Fapi%2Flogin&response_type=code&scope=user%3Aemail&state=c236a447-52c2-4761-986b-6d4ae1bff887
View testrealm.json
{
"realm": "tobedeleted",
"enabled": true,
"loginTheme": "fabric8",
"privateKey": "MIICXAIBAAKBgQCyM+ODEAdKbhj+IJUjqONXXYLtmpLODrbtLB4zPXf174OsenO68aGJPUBWgZ3mRN9nU19A8m75ZfnKKkRxfrrawQgoT7Ww5cDhaHuAEYF2+tlfet0Fvc6Q8j/LUPsWoG59Dx5N6yX2lu9p/JcFyZdPNb3FJGHWaXScVDPgufS0ZQIDAQABAoGAfKIl4Sh4sOnHuRT4ufQI7LWOOLf/LPbFoaNVi+jV2cAmi58pCfqtS9r3AImu8boBtbZtzHLCgtN7nJVrQSWtcNvH6HhutSxV3dzyH1G4fRsyL8BVUnqqaLGpR+J1Tq3s3QmP8iZoNrfg3YK1j6fEoasHW994AzN7PEN9+NM5HAECQQD3bC+aT6dLvO3KaUfLqj2s6kc0NGleHAT3n5mi2xjC82qSRipJxe/7/oa/aF1kc9xWAI6tlU8AETQKGjduLnYlAkEAuGFkraxg+xFpIp4XolqXt5vK/G/7+A4I6COdXOkYOzOnxptxDKnVJI+WQYWBKF7jigNHXCtwW+z7UcuUVXtRQQJALF8Jdmn8fZenKVqSFpM0NlNZa6JOlyL9PQ8xNUSHf0a6APt2T/6gWBfAQIlN3lrs07uL2tNg9IkhRQKImEjaxQJBALgKPvw7+/Gfx1mOg/jChH35O/wNq2xGVg2gvwpmgJFXVjigH4+MVfxQdqKgJ/OsA2NXMnuFwHmBarqSglVw6gECQGp+2Jg27pv1psU3ONcy0AUkAuIoObdC6z9WLEWXp08TWmycIFEVopiXIRNmlmkzwYxc4MJFBEvP6MBrmDsYK2k=",
"publicKey": "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCyM+ODEAdKbhj+IJUjqONXXYLtmpLODrbtLB4zPXf174OsenO68aGJPUBWgZ3mRN
View bootstrap.sh
#!/bin/bash
REALM="master"
CONTENT_OF_THE_JSONFILE=$(<testrealm.json)
export TKN=`curl -k -v -X POST "http://keycloak-kc-kishan.dev.rdu2c.fabric8.io/auth/realms/$REALM/protocol/openid-connect/token" \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "username=admin" \
-d 'password=admin' \
View bootstrap.sh
#!/bin/bash
REALM="master"
export TKN=`curl -k -v -X POST "http://keycloak-keycloak.192.168.42.52.nip.io/auth/realms/$REALM/protocol/openid-connect/token" \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "username=admin" \
-d 'password=admin' \
-d 'grant_type=password' \
-d 'client_id=admin-cli' | jq -r '.access_token'`