Skip to content

Instantly share code, notes, and snippets.

View DerPauli's full-sized avatar
📧
consulting@codezenith.com

Paul Merker DerPauli

📧
consulting@codezenith.com
View GitHub Profile
@DerPauli
DerPauli / change.py
Created April 11, 2020 15:23
Lambda function to change a imageDetails.json file into a imagedefinitions.json file
import json
import boto3
import zipfile
import tempfile
code_pipeline = boto3.client('codepipeline')
s3 = boto3.client('s3')
autoUpdate:
enabled: false
schedule: ""
bootConfigURL: https://gitlab.com/cz-sandbox/boot-jx
cluster:
clusterName: cicd
devEnvApprovers:
- cz-jx-bot
- DerPauli
environmentGitOwner: cz-sandbox
nginx-ingress:
controller:
replicaCount: 3
extraArgs:
publish-service: kube-system/jxing-nginx-ingress-controller
service:
omitClusterIP: true
{{- if eq .Requirements.cluster.provider "eks" }}
annotations:
service.beta.kubernetes.io/aws-load-balancer-type: alb
@DerPauli
DerPauli / values.tmpl.yml
Created January 11, 2020 14:54
jx chart for external-dns
external-dns:
enabled: {{ .Requirements.ingress.externalDNS }}
sources:
- ingress
{{- if eq .Requirements.cluster.provider "eks"}}
provider: aws
aws:
region: {{ .Requirements.cluster.region}}
securityContext:
fsGroup: 65534
@DerPauli
DerPauli / jx-requirements.yml
Created January 11, 2020 14:37
jx-requirements file
autoUpdate:
enabled: false
schedule: ""
bootConfigURL: https://github.com/codezenith/cz-jx-boot
cluster:
clusterName: cicd-cluster
environmentGitOwner: codezenith
environmentGitPublic: true
gitKind: github
gitName: github
@DerPauli
DerPauli / tooling.md
Last active November 5, 2019 10:21
List of macOS tooling
@DerPauli
DerPauli / reroute.sh
Created September 15, 2019 13:05
Reroute port 80 to 3000
sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 3000
sudo iptables-save
@DerPauli
DerPauli / https.js
Created August 31, 2019 15:50
Apollo https requirement -> generate self signed certificate
import express from 'express'
import { ApolloServer } from 'apollo-server-express'
import typeDefs from './graphql/schema'
import resolvers from './graphql/resolvers'
import fs from 'fs'
import https from 'https'
import http from 'http'
const configurations = {
// Note: You may need sudo to run on port 443
@DerPauli
DerPauli / oc.sh
Last active August 12, 2019 06:51
RedHat OpenShift cheat sheet
## Basic
# create new project
oc new-app <git_project> \
--source-secret=<optional_secret(basic auth + crt)> \
--build-env <build_environment_variables> \
--context-dir=<dir_for_dockerfile> \
-o yaml > <outfile>
# create a secret
oc create secret generic <secret_name> \