Skip to content

Instantly share code, notes, and snippets.

Clément Hussenot chussenot

Block or report user

Report or block chussenot

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
View .gitconfig
[core]
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
editor = nvim -f
autocrlf = false
safecrlf = true
excludesfile = ~/.gitignore
pager = diff-so-fancy | less --tabs=4 -RFX
[pull]
rebase = true
[push]
View misc.zsh
# Another quick function to shorten something like this:
# ps aux | grep PROCESS_NAME. (Usage: psa NAME)
psa () {
ps aux | grep $1
}
myuptime () {
uptime | awk '{ print "Uptime:", $3, $4, $5 }' | sed 's/,//g'
return;
}
View kibana.yml
# Kibana is served by a back end server. This setting specifies the port to use.
#server.port: 5601
# Specifies the address to which the Kibana server will bind. IP addresses and host names are both valid values.
# The default is 'localhost', which usually means remote machines will not be able to connect.
# To allow connections from remote users, set this parameter to a non-loopback address.
server.host: '0.0.0.0'
# Enables you to specify a path to mount Kibana at if you are running behind a proxy. This only affects
# the URLs generated by Kibana, your proxy is expected to remove the basePath value before forwarding requests
@chussenot
chussenot / react-cognito-auth-js.js
Created Jul 4, 2018 — forked from gabeweaver/react-cognito-auth-js.js
React + Cognito User Pools + Cognito Identity JS Example
View react-cognito-auth-js.js
/*
This example was built using standard create-react-app out of the box with no modifications or ejections
to the underlying scripts.
In this example, i'm using Google as a social provider configured within the Cognito User Pool.
Each step also represents a file, so you can see how I've chosen to organize stuff...you can do it however
you'd like so long as you follow the basic flow (which may or may not be the official way....but its what I found that works.
The docs are pretty horrible)
@chussenot
chussenot / cgroup.sh
Created Jun 13, 2018 — forked from teddyking/cgroup.sh
cgroup u/mounting
View cgroup.sh
#!/bin/bash
set -eu
function ensureMounted() {
source=$1
shift
target=$1
shift
type=$1
@chussenot
chussenot / rocker.rb
Created Jun 13, 2018 — forked from sczizzo/rocker.rb
Toy container runtime in Ruby
View rocker.rb
#!/usr/bin/env ruby
# Dependencies:
# - capsh
# - cgroup-utils
# - systemd
# - ruby
#
require 'fileutils'
require 'logger'
require 'optparse'
View models.py
from django.db import models
class Entry(models.Model):
name = models.CharField(max_length=20)
date = models.DateTimeField()
description = models.TextField()
created = models.DateTimeField(auto_now_add=True)
Sante = models.BooleanField(default=False)
Environnement = models.BooleanField(default=False)
Travail = models.BooleanField(default=False)
View -
[core]
pager = diff-so-fancy | less --tabs=4 -RFX
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
editor = nvim -f
autocrlf = false
safecrlf = true
excludesfile = ~/.gitignore
[pull]
rebase = true
[push]
View queues.rake
# rubocop:disable Style/HashSyntax
# shoryuken用のタスク
namespace :queues do
desc 'Create default SNS & SQS'
task 'setup' => :environment do
# http://qiita.com/takeyuweb/items/cdc262d97c3e863c15ff
# TODO
end
desc "List all SQS queues"
You can’t perform that action at this time.