Skip to content

Instantly share code, notes, and snippets.

View davidino's full-sized avatar

David Funaro davidino

  • AWS
  • Dublin
  • 14:19 (UTC +01:00)
View GitHub Profile
alias: Garbage bin reminder
description: ""
trigger:
- platform: time
at: "18:00:00"
condition:
- condition: time
before: "00:00:00"
weekday:
- wed
<?xml version="1.0" encoding="UTF-8"?><rss xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" version="2.0">
<channel>
<title>Dee Notte</title>
<link><![CDATA[http://www.deejay.it/audio/podcast/dee-notte/]]></link>
<description><![CDATA[Nicola Vitiello e Gianluca Vitiello ti aspettano in diretta Dee Notte!! In podcast riascolta il meglio dei loro programmi.]]></description>
<language>it-it</language>
<copyright>Copyright Elemedia S.p.A. 1999-2018</copyright>
<managingEditor>webmaster@deejay.it (Radio Deejay)</managingEditor>
<itunes:author>Radio Deejay</itunes:author>
function generateBC(url, separator) {
var elements = url.split('/')
elements.reduce((acc, value, index) => {
return index === 0 ?
generateTag('/', 'home', false) :
generateTag(`/${value}/`, value, index == elements.length -1 ? true: false)
},'')
}
function generateTag(href, name, active) {
function LCS(x, y) {
if (x.length == 0 | y.length == 0)
return '';
var res = []
x = x.split('');
y = y.split('');
y.forEach((ago, i) => {
x.forEach((pag, j) => {
@davidino
davidino / test.md
Last active December 21, 2016 15:26
shrink the vm

Problem

The vm is continuously growing. Even when you free space ( from inside ) then the virtual disk will not change the size:

Solution

Inside the VM run that command:

cd ~
sudo cat /dev/zero > zero;sync;sleep 1;sudo rm zero
@davidino
davidino / description.md
Last active February 25, 2016 08:07
docker-security-1.10

Docker security improvement - Username Space

As you already know Docker released the 1.10 version with a huge list of features. The list contains also a list of security improvment: one of that is the improving the user namespace

This is what it was happening before the version 1.10. We are just runnging an alpine container mounting an external volume /var/log/. :: include no-usernamespece.rd As you can see the ownership of the files in the container it is exactly the one outside the container ( because we are mounting the volume ). That means that the actual logget user in the container (root) can have access to these files and for example mess the up.

@davidino
davidino / vm.sh
Last active August 29, 2015 14:25 — forked from unlucio/vm.sh
simple vm management script
#!/bin/sh
if [ -z "$vmFile" ]
then
echo "please set your 'vmFile' environment variable to point to your vm's .vmx file"
exit 1
fi
case "$1" in
start)
@davidino
davidino / docker.md
Last active August 29, 2015 14:23
ssh command forwarding

In that way you can expose the docker service outside from the Virtual machine.

# /lib/systemd/system/docker.service
ExecStart=/usr/bin/docker -d -H tcp://0.0.0.0:2375 -H fd://

then

systemctl daemon-reload &amp;&amp; sudo service docker restart
@davidino
davidino / bio.md
Last active August 29, 2015 14:21
My Bio

David Funaro is a Software Engineer with more that 10 years of experience and a strong passion in building high maintainable software. He spent the last years coaching developer teams, providing tools, knowledge and method to get the software design always better. Building a team, He believe in people and he think that the right ones are those that has strong passion for that work. He continuously improve his knowledge getting updated, reading books/blogs and play with the new available tools. Over the years he has delivered software for companies such as Eni, Ferrari, Nissan, Samsung. Since he believes that communication is the most complex part to manage during the software development, he really trust on the value that the test methodologies like TDD and BDD are be able to provide. When he is not working you can find him riding some board (sea/snow).

short

David Funaro is a Software Engineer with more that 10 year

@davidino
davidino / list-shortcuts.md
Last active August 29, 2015 14:18
Tmux Shortcuts

My Shortcutlist

Define the prefix

Prefix = Ctrl-b