Skip to content

Instantly share code, notes, and snippets.

View skinofstars's full-sized avatar

Kevin Carmody skinofstars

View GitHub Profile
@LosEcher
LosEcher / drive_global_blacklist.filter
Created May 21, 2020 02:21
synology drive exclude folders config
[Version]
major = 1
minor = 1
[Common]
black_dir_prefix = "@tmp", "@eaDir", ".SynologyWorkingDirectory", "#recycle", "desktop.ini", ".ds_store", "Icon\r", "thumbs.db", "$Recycle.Bin", "@sharebin", "System Volume Information", "Program Files", "Program Files (x86)", "ProgramData", "#snapshot"
max_length = 0
max_path = 0
[File]
@mrtony
mrtony / react_formik_yup_checkbox_validation.md
Created October 15, 2018 01:31
React formik yup checkbox, radio button validation
import "./formik-demo.css";
import React from "react";
import { render } from "react-dom";
import { Formik, Field } from "formik";
import Yup from "yup";
import classNames from "classnames";

// Input feedback
@charity
charity / init.sh
Created May 18, 2016 20:19
terraform environment init.sh
#!/bin/bash
# Usage: ./init.sh once to initialize remote storage for this environment.
# Subsequent tf actions in this environment don't require re-initialization,
# unless you have completely cleared your .terraform cache.
#
# terraform plan -var-file=./production.tfvars
# terraform apply -var-file=./production.tfvars
tf_env="production"
@yefim
yefim / Dockerrun.aws.json
Last active April 7, 2023 16:11
Build a Docker image, push it to AWS EC2 Container Registry, then deploy it to AWS Elastic Beanstalk
{
"AWSEBDockerrunVersion": "1",
"Image": {
"Name": "<AWS_ACCOUNT_ID>.dkr.ecr.us-east-1.amazonaws.com/<NAME>:<TAG>",
"Update": "true"
},
"Ports": [
{
"ContainerPort": "443"
}
@joepie91
joepie91 / vpn.md
Last active April 20, 2024 21:15
Don't use VPN services.

Don't use VPN services.

No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.

Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.

  • A Russian translation of this article can be found here, contributed by Timur Demin.
  • A Turkish translation can be found here, contributed by agyild.
  • There's also this article about VPN services, which is honestly better written (and has more cat pictures!) than my article.
@pads
pads / bot.js
Created November 28, 2014 09:17
BrumJS Rock Paper Scissors Bot
var hands = [
'rock',
'paper',
'scissors',
'water',
'dynamite'
];
var opponents = []
"use strict";
function jsonToSassVars (obj, indent) {
// Make object root properties into sass variables
var sass = "";
for (var key in obj) {
sass += "$" + key + ":" + JSON.stringify(obj[key], null, indent) + ";\n";
}
// Store string values (so they remain unaffected)
@gshaw
gshaw / carrier_wave.rb
Created August 14, 2014 19:06
CarrierWave initialization file for testing with fixtures and support S3 in staging and production.
# NullStorage provider for CarrierWave for use in tests. Doesn't actually
# upload or store files but allows test to pass as if files were stored and
# the use of fixtures.
class NullStorage
attr_reader :uploader
def initialize(uploader)
@uploader = uploader
end
@joonty
joonty / unicorn
Created May 30, 2014 12:58
Unicorn service script
#!/bin/sh
### BEGIN INIT INFO
# Provides: unicorn
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Manage unicorn server
# Description: Start, stop, restart unicorn server for a specific application.
### END INIT INFO