Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View 2color's full-sized avatar
🚢

Daniel Norman 2color

🚢
View GitHub Profile
@2color
2color / README.md
Last active March 5, 2018 07:53 — forked from willejs/README.md
Moving Concourse Pipelines

Moving Concourse Pipelines

Intro

Currently concourse does not support moving pipelines between teams via fly CLI. There is an issue for that here

The only way to do this is to make a few changes in the DB.

If you run the statement below you will see that 6 tables have the team_id column.

concourse=> select table_name                                                                                                                                                                                                                                                                                                                                                       from INFORMATION_SCHEMA.COLUMNS                                                                                                                                                                                                                                                                   
@2color
2color / nginx.conf
Created October 18, 2017 06:56 — forked from plentz/nginx.conf
Best nginx configuration for improved security(and performance). Complete blog post here http://tautt.com/best-nginx-configuration-for-security/
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@2color
2color / postgres_queries_and_commands.sql
Created September 6, 2017 13:19 — forked from rgreenjr/postgres_queries_and_commands.sql
Useful PostgreSQL Queries and Commands
-- show running queries (pre 9.2)
SELECT procpid, age(query_start, clock_timestamp()), usename, current_query
FROM pg_stat_activity
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%'
ORDER BY query_start desc;
-- show running queries (9.2)
SELECT pid, age(query_start, clock_timestamp()), usename, query
FROM pg_stat_activity
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%'
@2color
2color / gist:2070f7870cc237ea7ab72e5276b149ff
Created September 5, 2017 14:47 — forked from mtigas/gist:952344
Mini tutorial for configuring client-side SSL certificates.

Client-side SSL

For excessively paranoid client authentication.

Using self-signed certificate.

Create a Certificate Authority root (which represents this server)

Organization & Common Name: Some human identifier for this server CA.

openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 365 -key ca.key -out ca.crt
@2color
2color / Button.jsx
Last active February 16, 2017 09:49 — forked from eloypnd/Button.jsx
Theme defaults with styled components
import styled from 'styled-components'
import themeVars from 'theme.variables'
const Button = styled.button`
background-color: ${({theme}) => theme.button.backgroundColor};
border: none;
border-radius: ${({theme}) => theme.button.radius}px;
color: white;
cursor: pointer;
padding: ${({theme}) => theme.button.padding}rem;
@2color
2color / server.js
Last active December 10, 2015 03:28 — forked from ccoenraets/server.js
var express = require('express'),
wine = require('./routes/wines');
var app = express();
app.configure(function () {
app.use(express.logger('dev')); /* 'default', 'short', 'tiny', 'dev' */
app.use(express.bodyParser());
});
@2color
2color / solarized (dark) theme.css
Created November 16, 2012 11:20 — forked from bradleypriest/solarized (dark) theme.css
JSONView Solarized (Dark) theme
body {
white-space: pre;
font-family: monospace;
font-family: inconsolata;
background: #042029;
color: #819090;
}
.property {
font-weight: normal;