Skip to content

Instantly share code, notes, and snippets.

Avatar

Will Rouesnel wrouesnel

View GitHub Profile
@wrouesnel
wrouesnel / gist:15d9359fc88b0937b6bf
Created Feb 21, 2016
Build command for totally static go images
View gist:15d9359fc88b0937b6bf
CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags '-s' -o main .
@wrouesnel
wrouesnel / gist:7c00af6e71a127308e34
Created Feb 27, 2016
JSON Injection for setting up LDAP on Gogs
View gist:7c00af6e71a127308e34
{
"AdminFilter": "adminfilter",
"AttributeMail": "email",
"AttributeName": "firstname",
"AttributeSurname": "lastname",
"AttributeUsername": "uid",
"AttributesInBind": false,
"BindDN": "",
"BindPassword": "",
"Enabled": true,
@wrouesnel
wrouesnel / Gulpfile.js
Last active Mar 6, 2016
Lightweight gulpfile for developing Webpack'd go-applications with CerebralJS.
View Gulpfile.js
/**
* Created by will on 6/09/15.
*/
var path = require('path');
var gulp = require('gulp');
var run = require('gulp-run');
var gutil = require('gulp-util');
var minimist = require('minimist');
View gist:6ecc953066b2d9ae8af8a353188189fc
(gdb) (gdb) Attaching to process 17801
Reading symbols from /usr/bin/cinnamon...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/cinnamon/libcinnamon.so...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libmuffin.so.0...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libgirepository-1.0.so.1...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libatk-bridge-2.0.so.0...Reading symbols from /usr/lib/debug/.build-id/03/5d5b0c2efd32e34e3bad20bceb30f1dd6ca99d.debug...done.
done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libclutter-1.0.so.0...Reading symbols from /usr/lib/debug/.build-id/a4/f1a53a1a4a0ea90c8e2e805d288df352026d5d.debug...done.
done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libX11.so.6...Reading symbols from /usr/lib/debug//usr/lib/x86_64-linux-gnu/libX11.so.6.3.0...done.
View gist:431d175f55aa646dbfe34a8e06f025bc
(gdb) (gdb) Attaching to process 18307
Reading symbols from /usr/bin/cinnamon...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/cinnamon/libcinnamon.so...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libmuffin.so.0...Reading symbols from /usr/lib/debug/.build-id/46/79bc47123fbb3697c66e8175e432a0ad11788b.debug...done.
done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libgirepository-1.0.so.1...(no debugging symbols found)...done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libatk-bridge-2.0.so.0...Reading symbols from /usr/lib/debug/.build-id/03/5d5b0c2efd32e34e3bad20bceb30f1dd6ca99d.debug...done.
done.
Reading symbols from /usr/lib/x86_64-linux-gnu/libclutter-1.0.so.0...Reading symbols from /usr/lib/debug/.build-id/a4/f1a53a1a4a0ea90c8e2e805d288df352026d5d.debug...done.
done.
@wrouesnel
wrouesnel / Dockerfile
Last active May 12, 2016
Centos7 and naked docker
View Dockerfile
FROM centos:7
RUN echo 'filesystems+="ext4"' > /etc/dracut.conf.d/supported_filesystems.conf
RUN yum update -y && \
yum install -y kernel ca-certificates \
systemd-networkd systemd-resolved
RUN update-ca-trust
View built-image
This file has been truncated, but you can view the full file.
./anaconda-post.log system_u:object_r:etc_runtime_t:s0
./.autorelabel
./bin system_u:object_r:bin_t:s0
./boot/config-3.10.0-327.18.2.el7.x86_64 system_u:object_r:boot_t:s0
./boot/grub/fonts system_u:object_r:boot_t:s0
./boot/grub/fonts/unicode.pf2 system_u:object_r:boot_t:s0
./boot/grub/grub.cfg system_u:object_r:boot_t:s0
./boot/grub/grubenv system_u:object_r:boot_t:s0
./boot/grub/i386-pc/915resolution.mod system_u:object_r:boot_t:s0
@wrouesnel
wrouesnel / Gulpfile.js
Last active Oct 19, 2016
webpack, react, golang self-contained gulpfile
View Gulpfile.js
var path = require('path');
var gulp = require('gulp');
var run = require('gulp-run');
var gutil = require('gulp-util');
var minimist = require('minimist');
var options = minimist(process.argv.slice(2), {
string: 'env',
@wrouesnel
wrouesnel / remote-backup.cmd
Created Jun 21, 2014
A batch file suitable for invoking a cygwin shell script which carries out a backup on Windows using unix-tooling.
View remote-backup.cmd
rem This batch file is executed by vscsc.exe after the shadow copy has been
rem created. It is used to initate the backup.
rem
rem %1 is the volume ID of the backup, we pass it to the bash script which
rem runs rsync for us.
c:\cygwin64\bin\bash.exe --login -i ./do-remote-backup.bsh "%1"
@wrouesnel
wrouesnel / zed.service
Last active Nov 14, 2016
systemd unit files for ZFS
View zed.service
[Unit]
Description=ZFS Event Daemon (zed)
Documentation=man:zed(8)
After=zfs-import-cache.service
After=zfs-import-scan.service
[Service]
Type=forking
ExecStart=/sbin/zed
PIDFile=/run/zed.pid