Skip to content

Instantly share code, notes, and snippets.

View start_elasticsearch_for_development.sh
#!/bin/bash
docker run -d --name elasticsearch -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" --restart=unless-stopped elasticsearch:6.8.4
View non-addictive-youtube-cjs.js
var h = function(selector){
document.querySelectorAll(selector).forEach(function(el){ el.style.display = 'none' })
}
var s = function(selector){
document.querySelectorAll(selector).forEach(function(el){ el.style.display = 'block' })
}
var pathContains = function(text){
return window.location.pathname.indexOf(text) !== -1
}
setInterval(function(){
View react_proficiency.txt
Senior (enterprise)
mid UX and SEO knowledge
Analyses and profile an application for performance and memory issues
Analyses and profile an application for security issues
Tune a production deployment
Understand and use Design Patterns (explain what they are, know some basic patterns)
Mentoring skills
Communication skills
Planning and Estimation
View fix-docker-gitlab.sh
#!/bin/bash
docker exec -it gitlab_app_1 gitlab-ctl reconfigure
docker exec -it gitlab_app_1 update-permissions
docker exec -it gitlab_app_1 chmod 2770 /var/opt/gitlab/git-data/repositories
View start_couchdb_for_development.sh
#!/bin/bash
docker run -p 5984:5984 -e COUCHDB_USER=admin -e COUCHDB_PASSWORD=admin --restart=unless-stopped -d --name couchdb couchdb
@ipepe
ipepe / exfat-install.sh
Created Sep 22, 2018
ExFat support on Ubuntu Server 18.04 LTS
View exfat-install.sh
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) universe"
sudo apt-get update
sudo apt-get install exfat-fuse exfat-utils
@ipepe
ipepe / deploy.rb
Last active Sep 2, 2018
Add my id_rsa.pub to authorized_keys in Capistrano
View deploy.rb
task :add_my_key_to_authorized_keys do
unless `cat "$HOME/.ssh/id_rsa.pub"`.empty?
id_rsa_pub_path = `echo "$HOME/.ssh/id_rsa.pub"`.strip
on roles(:all) do
upload! id_rsa_pub_path, "/tmp/id_rsa.pub"
execute 'cat /tmp/id_rsa.pub .ssh/authorized_keys | sort -u -o .ssh/authorized_keys'
execute 'cat .ssh/authorized_keys'
end
end
end
View gitlab-runner-in-docker.sh
docker run -d --name gitlab-runner --restart always -v /var/run/docker.sock:/var/run/docker.sock -v /opt/docker/gitlab-runner/config:/etc/gitlab-runner gitlab/gitlab-runner:latest
docker exec -it gitlab-runner /bin/bash
gitlab-runner register
@ipepe
ipepe / zerotier-install.sh
Last active Aug 31, 2020
Install zero-tier on linux
View zerotier-install.sh
curl -s https://install.zerotier.com | sudo bash
sudo cat /var/lib/zerotier-one/authtoken.secret >> ~/.zeroTierOneAuthToken
chmod 0600 ~/.zeroTierOneAuthToken
@ipepe
ipepe / smc-control.1s.rb
Created Aug 2, 2018
Cool but louder custom smc-controlled bitBar script
View smc-control.1s.rb
#!/usr/bin/env /Users/pptasinski/.rbenv/shims/ruby
MIN_TEMP = 40.0
MAX_TEMP = 70.0
FANS = {
0 => { min: 2200, max: 6100, delta: 6100-2200 },
1 => { min: 2100, max: 5600, delta: 5600-2100 }
}.freeze
temperature = `/usr/local/bin/smc -k TC0F -r`.match(/\d\d\.\d\d\d/).to_s.to_f
You can’t perform that action at this time.