Skip to content

Instantly share code, notes, and snippets.

View PaulusTM's full-sized avatar
🦄
Unicorn Power

Daniel Paulus PaulusTM

🦄
Unicorn Power
View GitHub Profile
@PaulusTM
PaulusTM / get-projects.py
Created August 18, 2017 14:24
Get Octopus projects
import requests
root_url = "<root_uri>"
api = "/api/projectgroups/all"
headers = {'X-Octopus-ApiKey':'<key>'}
response = requests.get(root_url+api, headers=headers)
projectgroups = response.json()
for group in projectgroups:
#cloud-config
---
hostname: {{VM_NAME}}
ssh_authorized_keys:
- ssh-rsa ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCX9ib81tx38a+I6FUQnG5iQMY/55nsbcvEATU2BQ//dK20/eRBAcDwV6Avswa6pAzf0uMueNi0ypOAAPtSKpAP5ohjoy5gN7Fd47hbCcnbcd1Nm3Q2nPsjDQz7oIc4DQwG+JLBytS1eTjQ/c6gSx3UW9+GJs7vuhdB3zi7+AzQM5qFEy11ZwNbf783LjKB7KunyUKmXF07sGqBjCkIP0KiQ8UnGyAcjt3ViRDuYiSfNoShYrWOGOeY5fH84eYTOS0dp6wciJVB15XasCKz0syqCadecHOV6fpX5w3x8xljitrbFjehHGquXLC2YM0oy3CvDhTY+detdvgbFjt+dMc5 dpaulus@DESKTOP-EKTG7IU
coreos:
etcd2:
name: {{VM_NAME}}
discovery: {{ETCD_DISCOVERY_TOKEN}}
@PaulusTM
PaulusTM / starwars.http
Last active January 31, 2019 14:11
This file is an example on how the use the Visual Studio Code REST Client plugin
### Search for the details of Luke Skywalker
# @name search
GET https://swapi.co/api/people/?search=luke HTTP/1.1
content-type: application/json
### Find the homeworld based on returned search details
# @name planet
GET {{search.response.body.$.results[0].homeworld}} HTTP/1.1
Content-Type: application/json
@PaulusTM
PaulusTM / DecryptJenkinsCredentials.groovy
Created October 14, 2019 19:55 — forked from sirrapa/DecryptJenkinsCredentials.groovy
Iterate and decrypt credentials (Security Breach!!!!)
def creds = com.cloudbees.plugins.credentials.CredentialsProvider.lookupCredentials(
com.cloudbees.plugins.credentials.Credentials.class,
Jenkins.instance,
null,
null
)
for(c in creds) {
println(String.format("%s --> %s: %s",c, c.id, c.description))
// if(c instanceof com.cloudbees.jenkins.plugins.sshcredentials.impl.BasicSSHUserPrivateKey){
@PaulusTM
PaulusTM / christmas.md
Created December 15, 2019 20:45
Card for the 25daysofserverless solution

Hi Buddy,

Hope that Santa brings you a cool race car and lots of other cool stuff!

Love,

Dad

@PaulusTM
PaulusTM / gist:e32615d4d3eb128f6a927d5cadc8becb
Last active February 4, 2025 14:02
TF cloudflare_page_rule debug log
2025-02-04T09:53:36.299Z [INFO] Terraform version: 1.10.3
2025-02-04T09:53:36.299Z [DEBUG] using github.com/hashicorp/go-tfe v1.70.0
2025-02-04T09:53:36.299Z [DEBUG] using github.com/hashicorp/hcl/v2 v2.23.0
2025-02-04T09:53:36.299Z [DEBUG] using github.com/hashicorp/terraform-svchost v0.1.1
2025-02-04T09:53:36.299Z [DEBUG] using github.com/zclconf/go-cty v1.15.1-0.20241111215639-63279be090d7
2025-02-04T09:53:36.299Z [INFO] Go runtime version: go1.23.3
2025-02-04T09:53:36.299Z [INFO] CLI args: []string{"terraform", "validate"}
2025-02-04T09:53:36.299Z [DEBUG] Attempting to open CLI config file: /home/vscode/.terraformrc
2025-02-04T09:53:36.299Z [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
2025-02-04T09:53:36.299Z [INFO] Loading CLI configuration from /home/vscode/.terraform.d/credentials.tfrc.json