Skip to content

Instantly share code, notes, and snippets.

View tabiodun's full-sized avatar

Tobi Abiodun tabiodun

  • Toronto, ON
View GitHub Profile
@tabiodun
tabiodun / Dockerfile
Last active April 24, 2018 21:33
Dockerfile for tabiodun/selenium-chrome-headless
FROM selenium/node-base:3.4.0-dysprosium
USER root
ARG CHROME_VERSION="google-chrome-beta"
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
&& echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list \
&& apt-get update -qqy \
&& apt-get -qqy install \
@tabiodun
tabiodun / Dockerfile
Last active August 22, 2020 08:06
chromedriver dockerfile
FROM ubuntu:14.04
# Install Chromium build dependencies.
RUN echo "deb http://archive.ubuntu.com/ubuntu trusty multiverse" >> /etc/apt/sources.list # && dpkg --add-architecture i386
RUN apt-get update && apt-get install -qy git build-essential clang curl
# Install Chromium's depot_tools.
ENV DEPOT_TOOLS /usr/bin/depot_tools
RUN git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git $DEPOT_TOOLS
ENV PATH $PATH:$DEPOT_TOOLS
@tabiodun
tabiodun / Dockerfile
Created July 19, 2017 17:20
Dockerfile for tabiodun/chrome-headless-ruby
FROM tabiodun/selenium-chrome-headless
RUN apt-get update && apt-get install -qy git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libmysqlclient-dev libffi-dev nodejs
RUN git clone git://github.com/rbenv/rbenv.git /usr/local/rbenv \
&& git clone git://github.com/rbenv/ruby-build.git /usr/local/rbenv/plugins/ruby-build \
&& git clone git://github.com/jf/rbenv-gemset.git /usr/local/rbenv/plugins/rbenv-gemset \
&& /usr/local/rbenv/plugins/ruby-build/install.sh
ENV PATH /usr/local/rbenv/bin:$PATH
ENV RBENV_ROOT /usr/local/rbenv
@tabiodun
tabiodun / Dockerfile
Created July 30, 2018 19:43
tabiodun/chrome-headless-node
FROM node:slim
USER root
ARG CHROME_VERSION="google-chrome-stable"
RUN apt-get update && apt-get install -y zip
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
&& echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list \
@tabiodun
tabiodun / controllers.application.js
Last active July 31, 2018 20:30 — forked from k-fish/controllers.application.js
Flex box margin transition
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
actions: {
toggle() {
this.toggleProperty('isIn');
}
}
import Ember from 'ember';
export default Ember.Component.extend({
didReceiveAttrs(){
var date = new Date;
var seconds = date.getSeconds();
var minutes = date.getMinutes();
var hours = date.getHours();
this.setProperties({hours, minutes, seconds})
},
@tabiodun
tabiodun / serialized_conversion.sql
Created December 13, 2018 00:41 — forked from statique/serialized_conversion.sql
PostgreSQL Convert Rails serialized YAML to JSON query
-- replace table_name with the name of your database table, e.g. users
-- replace data with the serialized field in the table, e.g. nicknames
-- output generates serialized data that decrypts to a Ruby array.
-- data with quotes, hyphens, or spaces will have issues with this query.
-- preview the YAML to JSON to confirm the conversion is working.
SELECT data, REPLACE(REPLACE(REPLACE(REPLACE(REGEXP_REPLACE(REPLACE(REPLACE(REPLACE(data,
' ', ''),
'...', ''),
'---', '["'),
import Ember from 'ember';
export default Ember.Controller.extend({
publishable: true,
actions: {
publish() {
console.log('publish');
}
}
import Ember from 'ember';
export default Ember.Component.extend({
});
import Ember from 'ember';
export default Ember.Component.extend({
});