Skip to content

Instantly share code, notes, and snippets.

coverboy

Block or report user

Report or block coverboy

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@coverboy
coverboy / Lets_Encrypt_Synology_Gitlab.MD
Created Jun 9, 2019 — forked from mattcarlotta/Lets_Encrypt_Synology_Gitlab.MD
Lets Encrypt - Synology NAS + sameersbn/docker-gitlab (HTTPS)
View Lets_Encrypt_Synology_Gitlab.MD

Let's Encrypt - Synology NAS + sameersbn/docker-gitlab

Getting HTTPS on a Synology NAS + Gitlab container is a bit tricky. Using self-assigned OpenSSL certificates is great, but it can only provide SSL certificates that inevitably will be flagged as untrusted by the browser due to the common name being unrecognized/not associated with a trusted SSL provider:

The downside will be that every user that remotely accesses your NAS will be greeted with the above message unless they manually add the certificate to their browser's approved SSL provider list. Instead, here's a work-around to enable HTTPS for both your Synology NAS and a Gitlab container using just one Let's Encrypt certification.

For more information regarding the docker-gitlab installation and set up: Synology Docker

@coverboy
coverboy / curl.md
Created Mar 5, 2019 — forked from subfuzion/curl.md
curl POST examples
View curl.md

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@coverboy
coverboy / app.js
Created Oct 21, 2018 — forked from sogko/app.js
gulp + expressjs + nodemon + browser-sync
View app.js
'use strict';
// simple express server
var express = require('express');
var app = express();
var router = express.Router();
app.use(express.static('public'));
app.get('/', function(req, res) {
res.sendfile('./public/index.html');
@coverboy
coverboy / search-git-history.md
Created Aug 22, 2018 — forked from lyoshenka/search-git-history.md
Search Git commit history for a string and see the diffs
View search-git-history.md

Searching Git commit history

This should be one of the core features of Git, but for some reason it's impossible to figure out how to search for a string in your commit history and see the diffs that that string is in. Here's the best I've come up with:

To find which commits and which files a string was added or removed in:

git log -S'search string' --oneline --name-status

To see the diff of that

@coverboy
coverboy / README.md
Created Aug 3, 2018 — forked from MarkTiedemann/README.md
An Easier Way to Enforce Required Parameters in ES6
View README.md

An Easier Way to Enforce Required Parameters in ES6

Expands on Handling required parameters in ECMAScript 6 by Axel Rauschmayer.

The idea (which is credited to Allen Wirfs-Brock) is, in essence, to use default parameter values to call a function which throws an Error if the parameter is missing:

const throwIfMissing () => { throw new Error('Missing parameter') }
@coverboy
coverboy / index.html
Last active Sep 16, 2018
html5 skeleton template
View index.html
<!doctype html>
<html lang="en">
<!--한글은 lang="ko" Learn more : https://www.w3.org/International/questions/qa-html-language-declarations-->
<head>
<meta charset="utf-8">
<title></title>
<meta name="description" content="">
<meta name="author" content="">
<meta name="keywords" content="">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0">
You can’t perform that action at this time.