Skip to content

Instantly share code, notes, and snippets.

View nagubal's full-sized avatar

nagubal nagubal

  • Combourg, France
View GitHub Profile
@nagubal
nagubal / docker-compose.yml
Last active March 14, 2019 09:21
docker-compose for mariadb & phpmyadmin
---
version: "2"
services:
db:
image: mariadb:latest
container_name: mariadb
environment:
- MYSQL_ROOT_PASSWORD=mypass
volumes:
- /docker/containers/mariadb/data:/var/lib/mysql
*filter
# Base policy
:INPUT DROP [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [0:0]
# Don't attempt to firewall internal traffic on the loopback device.
-A INPUT -i lo -j ACCEPT
@nagubal
nagubal / SegmentClock_2016.ino
Last active March 14, 2016 18:39
A 2.3" 4 digits 7-segment arduino clock, using the DE-DP003 from Sure Electronics, and temperature reading using a DS18B20 sensor - Uses old libraries
/**
* USE_GITHUB_USERNAME=nagubal
*
* 2.3" 4 digits 7-segment clock, using the DE-DP003 from Sure Electronics
* http://www.sure-electronics.net/mcu,display/DE-DP003.pdf
*
* The DE-DP003 is a common anode 7-segment LED display.
* The LED driver chips are composed of 4pcs of 74HC595 and 5pcs of ULN2003.
* Data should be clocked in from CLK_IN and DATA_IN in J1, and DIMM_IN pin should be pull to low to enable display.
* PWM signal can be applied on the DIMM_IN pin to control brightness.
@nagubal
nagubal / SegmentClock_DS3231.ino
Last active March 14, 2016 22:12
The file that is currently on an Arduino Uno with a serial number of 64935343333351F04132
/**
* USE_GITHUB_USERNAME=nagubal
*
* 2.3" 4 digits 7-segment clock, using the DE-DP003 from Sure Electronics
* http://www.sure-electronics.net/mcu,display/DE-DP003.pdf
*
* The DE-DP003 is a common anode 7-segment LED display.
* The LED driver chips are composed of 4pcs of 74HC595 and 5pcs of ULN2003.
* Data should be clocked in from CLK_IN and DATA_IN in J1, and DIMM_IN pin should be pull to low to enable display.
* PWM signal can be applied on the DIMM_IN pin to control brightness.
@nagubal
nagubal / rsync-workspace.sh
Created May 3, 2009 19:51
Backup with cygwin/rsync shell script
#!/bin/sh
# rsync-workspace.sh : Sauvegarde rsync du workspace Eclipse
EXIT_KO=5
srcdir=/cygdrive/d/workspace/
destvol=/cygdrive/e
destdir=$destvol/workspace/
if [ ! -e $destvol ] && [ ! -d $destvol ];
@nagubal
nagubal / iTunes backup to Syno.scpt
Created May 3, 2009 19:33
Applescript to backup iTunes library to syno
-- Sauvegarde de la librairie iTunes sur le synology via rsync
property appName : "Sauvegarde iTunes"
property rsyncUri : "rsync://syno:22/music/"
property iTunesFolder : "/Users/anthony/Music/iTunes"
on tellGrowl(myid, myTitle, myMessage, isSticky) -- the growl notification routine
global growlIsRunning
if growlIsRunning then -- is growl running?
tell application "GrowlHelperApp"