This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Base image. | |
FROM fotinakis/baseimage-ruby:2.1.3 | |
# System dependencies for gems. | |
RUN apt-get update | |
RUN apt-get install -y --no-install-recommends libmysqlclient-dev | |
# Add 'web' user which will run the application. | |
RUN adduser web --home /home/web --shell /bin/bash --disabled-password --gecos "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FIX FOR: Couldn't connect to Docker daemon at http+unix://var/run/docker.sock - is it running? | |
Change the DOCKER_OPTS in /etc/default/docker to: | |
DOCKER_OPTS="-H tcp://127.0.0.1:4243 -H unix:///var/run/docker.sock" | |
Ruslan Khamidullin [1:57 PM] netstat -ant |grep 4243 | |
tcp 0 0 127.0.0.1:4243 0.0.0.0:* LISTEN | |
Ruslan Khamidullin [1:57 PM] export DOCKER_HOST=tcp://localhost:4243 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<li class="<%= self_or_other(message) %>"> | |
<div class="avatar"> | |
<img src="http://placehold.it/50x50" /> | |
</div> | |
<div class="chatboxmessagecontent"> | |
<p><%= message.body %></p> | |
<time datetime="<%= message.created_at %>" title="<%= message.created_at.strftime("%d %b %Y at %I:%M%p") %>"> | |
<%= message_interlocutor(message).name %> • <%= message.created_at.strftime("%H:%M %p") %> | |
</time> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Swift Programming Language Guide | |
"A Swift Tour" Solutions | |
https://developer.apple.com/library/prerelease/ios/documentation/Swift/Conceptual/Swift_Programming_Language/GuidedTour.html#//apple_ref/doc/uid/TP40014097-CH2-XID_1 | |
These are the solutions to all the "experiments" in the pre-release Swift Programming Guide | |
(released on the same day Apple announced Swift). A couple of things worth noting: | |
1. Swift syntax, e.g. array declarations, has changed since I releasd these. So this code will | |
probably cause some errors when you paste it into a playground. Should be easy enough to fix |
Here's what I did to get things working.
Yep, over at: https://developer.apple.com
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'openssl' | |
require 'digest/sha1' | |
require 'base64' | |
require 'json' | |
def go_demo! | |
key = Digest::SHA1.hexdigest("clave1")[0..15] # 16bytes => 128bits | |
iv = 'clave2 con chicha'[0..15] # 16bytes forced | |
data = { esto: 'es', un: 'hash', en: 'ruby' } |
Create droplet of your liking (ubuntu 12.10 x32)
ssh to root in terminal with your server ip
ssh [email protected]
Add ssh fingerprint and enter password provided in email
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
puts "2.10.3".split(".")[0..1].join(".") |
Fortunately GIT has a very easy solution for this, just run the following command on the file or path you want to ignore the changes of:
git update-index --assume-unchanged <file>
If you wanna start tracking changes again run the following command:
git update-index --no-assume-unchanged <file>
source: http://blog.pagebakers.nl/2009/01/29/git-ignoring-changes-in-tracked-files/
NewerOlder