Saturday, November 22, 2014

Surviving zombie apocalypses for fun an profit

Another Codemotion came and went. All in all it wasn't bad, considering its dimension and organizational challenges.

As a former international event volunteer organizer, I find myself in deep empathy with the enormous achievement of making this happen. Near 2000 people, 8 tracks, 2 days...

On the other hand, as a conference attendee, I have suffered the price of some of those numbers.

The size

It's too big, corridors and talk-rooms get unevenly crowded, and you loose interesting talks because they get full.

The food you can offer to 2K people does not leave much place for excellence, and there was even some twitter trolling related to this, I will just say it was dull and felt cheap.

It is impossible for any crew to reasonably choose technically relevant talks of such diverse branches, so they delegate in the local communities with mixed results, there is not an uniform quality level in the contents, nor in the delivery.

The venue

I have no opinion on San Pablo CEU as an educational institution, I just don't appreciate religious indoctrination mixed with my tech talks, they every right to mix it into education as long as it is a private educational institution, and students or parents choose freely to attend it.

I do no appreciate either having to take the car to go a place wrongly mapped by popular GPS software that non one in the crew tried before recommending.

I find id a bad choice, horribly far from down-town for locals, and even worse for attendees coming from other provinces that had to search for accommodation in Madrid and suffer a weirdest commute to get there.

Rooms where crowded on the most popular tracks, which is very difficult to avoid when you go for 8-tracks, which is one of the reasons you shouldn't.

The talks

I was quite lucky and saw a good deal of decent talks. But I lost two I wanted to go because of full rooms, even after seeing people sitting in the ground during several talks from the first day.

Special mentions to @serabe@arctarus @carlossanchezp, @alvaro_sanchez@olmaygti@jorgeleria@vianasw, @chemaalonso, @david_bonilla whose talks I liked specialy.

David Bonilla's talk and call to action deserves a post on their own, but there will be many and probably better than the one I would do, so I will try to transform that energy on deeds instead of more words.

Thanks to my really nice employer for my free day :-)

If you want to see the slides of any of them, just help yourself:

Thursday, November 13, 2014

Adventure Time

Last month I jumped onto a new challenge. I have entered the ranks of We Are People Engineering. It is a (for now) small code-shop in Madrid which values and views I have find myself significantly aligned with.

A year ago I did another jump in the void when I embarked Avature, leaving behind among other things ruby and backend development, which had been my specialities for the last lustrum and more.

This new course change obeys not to regret on that decision but to a deeper understanding of what I like and find important in the craft.

I value every day I have spent outside of my comfort zone, every challenge to my beliefs, every proof that my old ways where not the only ones... It has been enlightening as only living abroad and learning a different language can be. But one can get homesick abroad.

Many Spanish companies that I know of have a lot to learn form Avature about how they treat people. Their approach to onboarding and team building is more human and peer-like than anything I saw before. That, much more than the very decent salary, is the reason I pursued this journey to strangeland so far. That and the very good company from the Madrid team (kudos to you all, pals).

This are not easy things to leave behind, and thus I did not so lightly. My current affair is one of meaningful comprehension of a shared core of values. I walk away from a lot of good things because I think my contributions will be more meaningful to WeArePeople, and I hope to the community.

Change is what life is made of, may you all live interesting times.

Friday, September 26, 2014

A happy developer's environment: part 1

I have been working lately with my development stack held inside a linux container (LXC), and it has been my best sandboxing experience so far, so I decided to share the process with everyone.

In this first part I will cover the vagrant and lxc installation and the box creation, later in part 2 I will cover provision and backup of the box.

Install lxc

sudo apt-get install lxc

Install Vagrant

Go to and download and install the appropiate one for you

Install Vagrant-LXC plugin

vagrant plgin install  vagrant-lxc

Clone Vagrant-LXC-boxes repo

git clone

Build a base box with your provisioner of choice

CHEF=1 make precise
==> [ubuntu-precise] Building box to 'output/2014-09-26/'...
    [ubuntu-precise] Creating container...
    [ubuntu-precise] Container created!
    [ubuntu-precise] Adding ipv6 allhosts entry to container's /etc/hosts
    [ubuntu-precise] Running [/usr/sbin/locale-gen es_ES.UTF-8] inside 'vagrant-base-precise-amd64' container...
    [ubuntu-precise] Running [update-locale LANG=es_ES.UTF-8] inside 'vagrant-base-precise-amd64' container...
==> [ubuntu-precise] Installing extra packages and upgrading
    [ubuntu-precise] Sleeping for 5 seconds...
    [ubuntu-precise] Running [apt-get update] inside 'vagrant-base-precise-amd64' container...
    [ubuntu-precise] Running [apt-get install vim software-properties-common nfs-common curl wget man-db bash-completion python-software-properties ca-certificates sudo -y --force-yes] inside 'vagrant-base-precise-amd64' container...
    [ubuntu-precise] Running [apt-get upgrade -y --force-yes] inside 'vagrant-base-precise-amd64' container...
    [ubuntu-precise] Installing Chef
    [ubuntu-precise] Running [/tmp/] inside 'vagrant-base-precise-amd64' container...
    [ubuntu-precise] Skipping Puppet installation
    [ubuntu-precise] Skipping Salt installation
    [ubuntu-precise] Skipping Babushka installation
==> [ubuntu-precise] Preparing vagrant user...
    [ubuntu-precise] Renamed ubuntu user to vagrant and changed password.
    [ubuntu-precise] SSH credentials configured for the vagrant user.
    [ubuntu-precise] Sudoers file created.
==> [ubuntu-precise] Cleaning up 'vagrant-base-precise-amd64'...
    [ubuntu-precise] Removing temporary files...
    [ubuntu-precise] cleaning up dhcp leases
    [ubuntu-precise] Removing downloaded packages...
    [ubuntu-precise] Running [apt-get clean] inside 'vagrant-base-precise-amd64' container...
==> [ubuntu-precise] Packaging 'vagrant-base-precise-amd64' to 'output/2014-09-26/'...
    [ubuntu-precise] Removing previous rootfs tarball
    [ubuntu-precise] Compressing container's rootfs
    [ubuntu-precise] Preparing box package contents
    [ubuntu-precise] Packaging box
==> [ubuntu-precise] Finished building 'output/2014-09-26/'!
    [ubuntu-precise] Run `sudo lxc-destroy -n vagrant-base-precise-amd64` or `make clean` to remove the container that was created along the way

Move/rename box

mv output/2014-09-26/ ../

Remove build artifacts

make clean
cd ..

Create a Vagrantfile


Vagrant.configure("2") do |config| = "precise64"
  config.vm.box_url = "./"
  config.vm.provider :lxc do |lxc|
    # Same effect as 'customize ["modifyvm", :id, "--memory", "1024"]' for VirtualBox
    # lxc.customize 'cgroup.memory.limit_in_bytes', '1024M'

Set up NFS folder sync (if you want)

On the server:

Add to the Vagrantfile:
config.vm.synced_folder './code', '/home/vagrant/code', nfs: true

As root add in /etc/apparmor.d/lxc/lxc-default:
profile lxc-container-default flags=(attach_disconnected,mediate_deleted) {
    mount options=(rw, bind),
Reload apparmor:
sudo /etc/init.d/apparmor reload

Launch Vagrant (it will import the .box the first time)

vagrant up
Bringing machine 'default' up with 'lxc' provider...
==> default: Setting up mount entries for shared folders...
    default: /vagrant => /tmp/lxc
==> default: Starting container...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address:
    default: SSH username: vagrant
    default: SSH auth method: private key
==> default: Machine booted and ready!
==> default: Exporting NFS shared folders...
==> default: Preparing to edit /etc/exports. Administrator privileges will be required...
nfsd running
==> default: Mounting NFS shared folders...
==> default: Machine already provisioned. Run `vagrant provision` or use the `--provision`
==> default: to force provisioning. Provisioners marked to run always will still run.
If you get tired of writing your password:
vagrant lxc sudoers

Access the machine

vagrant ssh
Welcome to Ubuntu 12.04.5 LTS (GNU/Linux 3.13.0-35-generic x86_64)

 * Documentation:
And that's all, you are in, if you just wanted to have an isolated environment to make experiments without paying for servers or loosing performance like virtual machines, then you are good to go.

Otherwise, if you are still interested in the provisioning thing keep tuned for the second part.

Thursday, February 6, 2014

May you live in interesting times

A few months ago I left the cozy valley of Ruby and Rails, leaving also behind the project and team I have been part since late 2006.

It was a leap of faith. Unless you have been living under a rock since 2008 you may have seen this motivational picture along some social network or another:

This message is part of a culture of challenge forwarding. Lots of people click, share, thumb-up, plusify or commit whatever other cheap online interaction about taking action, getting off the couch, going out there and changing things.

There are like two main currents often mixing, the free yourself from... to which you may attribute this picture , and the save the world one. There is no real difference, most of us, most of the time upon encountering any of this challenges do the same thing: nod, mumble «aha», click some action surrogate button and go on with our lives. That's the reason most people doesn't have adventurous lives and even te reason most governments rule unbothered until replaced by an indistinguishable corrupt and dull one.

I have let many of such calls to action pass and fade in the past. Becoming a dad is a juicy excuse for letting yourself settle. You have to stick around and keep things going...

But I have a dad, and he didn't settled, he had a good job he already knew, but he took the chance and started his own business. It may not sound like much but at 26% unemployment rate we have now, having created and preserved up to three jobs for over 15 years is an epic quest.

I have tried to start a business with a friend while I was at my old job, it was made of side-projects and it failed. You could point many reasons, but the main one is that I was trying instead of doing...

...and there is no «try».

That's the reason I accepted the challenge to go first league, to go fulltime frontend and fulltime javascript. That's how I left behind the ruby guy I have been for so long. Because despite of being the craziest thing one could do in these times, it is the only thing I could do because not doing it, was above all: not doing.

Let's honour Sam's wise words about true adventure:

Wish me well while I go bodly where I have never gone before.