This file contains hidden or 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
FROM buildpack-deps:jessie | |
ADD . /root/.ssh | |
RUN chown -R root:root /root/.ssh | |
RUN apt-get update | |
RUN apt-get install -y mysql-client socat | |
expose 3306 | |
CMD socat tcp-l:3306,fork,reuseaddr tcp:127.0.0.1:3307 & ssh -N frontend |
This file contains hidden or 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
import _ from 'underscore'; | |
import fetch from 'isomorphic-fetch' | |
class API { | |
getCSRFToken() { | |
return _.find(document.getElementsByTagName('meta'), (meta) => { | |
return meta.name === 'csrf-token' | |
}).content | |
} |
This file contains hidden or 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
class CB | |
def self.flatten(arr) | |
flat_array = [] | |
arr.each do |e| | |
if e.is_a?(Array) | |
CB.flatten(e).each {|se| flat_array << se } | |
else | |
flat_array << e | |
end | |
end |
This file contains hidden or 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
docker run --name rails_updated -v "$PWD":/usr/src/rp -w /usr/src/rp rails/updated gem install minitest:5.8.1 json:1.8.3 \ | |
debug_inspector:0.0.2 binding_of_caller:0.7.2 byebug:6.0.2 coffee-script-source:1.9.1.1 execjs:2.6.0 coffee-script:2.4.1 \ | |
coffee-rails:4.1.0 multi_json:1.11.2 jbuilder:2.3.2 jquery-rails:4.0.5 sass:3.4.19 tilt:2.0.1 sass-rails:5.0.4 sdoc:0.4.1 \ | |
spring:1.4.0 sqlite3:1.3.11 turbolinks:2.5.3 uglifier:2.7.2 | |
docker commit rails_updated rails/updated && docker rm rails_updated |
This file contains hidden or 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
package main | |
import ( | |
"fmt" | |
) | |
type Fetcher interface { | |
Fetch(url string) (body string, urls []string, err error) | |
} |