Skip to content

Instantly share code, notes, and snippets.

View stefanwalther's full-sized avatar
🏠
Working from home

Stefan Walther stefanwalther

🏠
Working from home
View GitHub Profile
@pdxjohnny
pdxjohnny / .gitignore
Last active February 23, 2024 18:12
Setting Up k3s for Serverless (knative) on a $5 DigitalOcean Droplet Using k3d
.terraform/
*.pem
*.tf
*.tfstate
*.yaml
*.backup
istio-*/
cert-manager-*/
*.swp
env
@AlexAegis
AlexAegis / base.directive.ts
Last active August 21, 2020 02:05
Angular subscription handler, unsubscribes when the component is destroyed
import { OnDestroy } from '@angular/core';
import { Subscription } from 'rxjs';
/**
* Adds a subscription object and a default OnDestroy hook to the child component
*
* If ngOnDestroy is is overriden in the child component don't forget to call
* ```typescript
* super.ngOnDestroy();
* ```
@PARC6502
PARC6502 / OpenSourceBaas.md
Last active May 4, 2024 18:15
List of open source, self hosted BaaS - Backend as a service

Backend as a Service

Supabase - ~52K stars

  • Designed explicitly as an open source firebase alternative
  • Typescript based
  • Docker support

Appwrite - ~32K stars

  • Written in JavaScript and PHP
  • Docker based
  • Realtime support across all services
@posener
posener / go-shebang-story.md
Last active March 29, 2024 08:38
Story: Writing Scripts with Go

Story: Writing Scripts with Go

This is a story about how I tried to use Go for scripting. In this story, I’ll discuss the need for a Go script, how we would expect it to behave and the possible implementations; During the discussion I’ll deep dive to scripts, shells, and shebangs. Finally, we’ll discuss solutions that will make Go scripts work.

Why Go is good for scripting?

While python and bash are popular scripting languages, C, C++ and Java are not used for scripts at all, and some languages are somewhere in between.

@Ashton-W
Ashton-W / Issue.md
Last active April 23, 2024 17:19
GitHub Markdown toggle code block
Click to toggle contents of `code`
CODE!
@frank-leap
frank-leap / digitalocean-swarm.sh
Last active March 16, 2023 13:22
Script to create a Docker Swarm cluster in Digital Ocean
#!/bin/bash
# Configuration
#export DIGITALOCEAN_ACCESS_TOKEN= # Digital Ocean Token (mandatory to provide)
export DIGITALOCEAN_SIZE=512mb # default
export DIGITALOCEAN_REGION=nyc3 # default
export DIGITALOCEAN_PRIVATE_NETWORKING=true # default=false
#export DIGITALOCEAN_IMAGE="ubuntu-15-04-x64" # default
# For other settings see defaults in https://docs.docker.com/machine/drivers/digital-ocean/
@jmshal
jmshal / create-multi-host-swarm-digitalocean.sh
Last active March 16, 2023 13:22
Setup a Docker Swarm multi-host cluster on DigitalOcean
docker-machine create \
--driver=digitalocean \
--digitalocean-access-token=$DO_TOKEN \
--digitalocean-size=512mb \
--digitalocean-region=nyc3 \
--digitalocean-private-networking=true \
--digitalocean-image=ubuntu-15-04-x64 \
docker-swarm-kv-store
docker $(docker-machine config docker-swarm-kv-store) run -d \
@nate-untiedt
nate-untiedt / wblGen.bat
Last active October 8, 2021 00:33
A simple batch file that automatically generates the wblfolder.wbl for your Qlik Sense visualization extension.
@echo off
REM wblGen.bat - v 1.0.0 - 2015-10-09
REM Description:
REM A simple batch file that automatically generates the wblfolder.wbl for your Qlik Sense visualization extension.
REM
REM Author: Nate Untiedt - Analytics8 - nuntiedt@analytics8.com
REM
REM Credit to: http://stackoverflow.com/a/8387078
setlocal EnableDelayedExpansion
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 3, 2024 18:53
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@bayleedev
bayleedev / mongoose.js
Last active December 26, 2019 09:11
A better syntax for mongoose instance and static methods.
var mongoose = require('mongoose');
mongoose.connect('mongodb://localhost/foobar');
// bootstrap mongoose, because syntax.
mongoose.createModel = function(name, options) {
var schema = new mongoose.Schema(options.schema);
for (key in options.self) {
if (typeof options.self[key] !== 'function') continue;
schema.statics[key] = options.self[key];
}