Skip to content

Instantly share code, notes, and snippets.

💾
0x01

Karl Fischer fishi0x01

💾
0x01
Block or report user

Report or block fishi0x01

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View measureTraffic.sh
#! /bin/bash
usage() {
echo "measureTraffic.sh <targetIP>"
}
if [ -z "$1" ]; then
usage
exit 1
fi
View jenkins.yaml
---
jenkins:
systemMessage: "Powered automagically by Groovy and Configuration-as-Code Plugin\n\n"
numExecutors: 5
crumbIssuer:
standard:
excludeClientIPFromCrumb: false
remotingSecurity:
View multibranchJobs.groovy
projects = [
[name: "serviceA", cron: "@daily"],
[name: "serviceB", cron: "@hourly"],
[name: "serviceC", cron: "@daily"],
]
for(project in projects) {
folder("${project.name}")
View ConfigurationAndSeedingPipeline.groovy
node('master') {
stage('Checkout') {
// Clean workspace and checkout shared library repository on the jenkins master
cleanWs()
checkout scm
}
stage('Configuration') {
// set CasC config in master
sh('cp /var/jenkins_home/workspace/Admin/Configure/resources/config/configuration-as-code-plugin/jenkins.yaml /var/jenkins_home/jenkins.yaml')
View keybase.md

Keybase proof

I hereby claim:

  • I am fishi0x01 on github.
  • I am fishi (https://keybase.io/fishi) on keybase.
  • I have a public key ASAJZDqCC63ash9grQadaoo1nAzw8uhByx8JRuj2nFR5Hgo

To claim this, I am signing this object:

@fishi0x01
fishi0x01 / baseURL.groovy
Last active Aug 19, 2019
This is a collection of groovy scripts I gathered and use for bootstrapping Jenkins. Most of this can also be achieved with the CasC Plugin https://github.com/jenkinsci/configuration-as-code-plugin
View baseURL.groovy
#!groovy
/*
* This script configures the Jenkins base URL.
*/
import jenkins.model.JenkinsLocationConfiguration
JenkinsLocationConfiguration location = Jenkins.instance.getExtensionList('jenkins.model.JenkinsLocationConfiguration')[0]
location.url = 'https://jenkins-as-code-poc.devtail.io/'
@fishi0x01
fishi0x01 / terraform-0.7.11-experimental-feature-bug
Last active Nov 22, 2016
Terraform 0.7.11 Experimental Feature Error on aws_instance resource
View terraform-0.7.11-experimental-feature-bug
While running, Terraform sometimes tests experimental features in the
background. These features cannot affect real state and never touch
real infrastructure. If the features work properly, you see nothing.
If the features fail, this message appears.
The following failures happened while running experimental features.
Please report a Terraform bug so that future Terraform versions that
enable these features can be improved!
You can report an issue at: https://github.com/hashicorp/terraform/issues
@fishi0x01
fishi0x01 / Dockerfile
Last active Jul 31, 2019
Jenkins Pipeline as Code. Code for blog post http://fishi.devtail.io/weblog/E/
View Dockerfile
FROM tomcat:8.0.38
# Place the code version inside the webapps directory
ARG PACKAGE_VERSION
RUN echo "${PACKAGE_VERSION}" >> /usr/local/tomcat/webapps/version.txt
COPY project.war /usr/local/tomcat/webapps/project.war
COPY docker-entrypoint.sh /
RUN chmod +x /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
@fishi0x01
fishi0x01 / dcom-access-x64.ps1
Last active Dec 3, 2016
Script to configure DCOM remote access on Windows machines. Code for blog post http://fishi.devtail.io/weblog/2/
View dcom-access-x64.ps1
# Original script taken and modified from http://shrekpoint.blogspot.de/2012/08/taking-ownership-of-dcom-registry.html
#
# Enable remote DCOM access to the WbemScripting.SWbemLocator class on 64-bit Windows 7/8 and Server 2012 machines,
# by setting the necessary keys inside the registry.
# Use this script at your own risk.
# I do not guarantee that it works, nor do I give any kinds of support in case it doesn't
Try {
[void][TokenAdjuster]
} Catch {
@fishi0x01
fishi0x01 / defaults-main.yml
Last active Dec 3, 2016
Snippets for ansible role structuring. Code for blog post http://fishi.devtail.io/weblog/D/
View defaults-main.yml
sshd_port: 5133
sshd_groups:
- name: devops
ssh:
allow_tcp_fwd: True
allow_agent_fwd: True
x11_fwd: True
- name: developers
ssh:
You can’t perform that action at this time.