- Go to Digital Ocean
- Create new droplet
- London
- Ubuntu
- No apps
- Add SSH keys
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
// The MIT License | |
// Copyright (c) 2018 Daniel | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to deal | |
// in the Software without restriction, including without limitation the rights | |
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
// copies of the Software, and to permit persons to whom the Software is | |
// furnished to do so, subject to the following conditions: |
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
Phoenix esbuild with Tailwind+Fontawesome |
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
/** | |
* Wrapper around terragrunt to display output succinctly on Atlantis. | |
* | |
* Terragrunt is notoriously verbose, which can cause Atlantis to output | |
* hundreds of comments on single PRs, which can be annoying. | |
* | |
* This script will output just the final plan for resources to update on | |
* successful terragrunt runs, but will output all terragrunt output on | |
* errors. | |
*/ |
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
var dqData=[]; | |
dqData.push({title:'Product Groups', | |
mean:0.0393, | |
dP:[ | |
['GROUP01',-0.0435,32937], | |
['GROUP10',-0.2651,132], | |
['GROUP11',-0.0694,1164], | |
['GROUP12',0.0345,17127], | |
['GROUP13',-0.0288,8858], | |
['GROUP18',-0.3741,46], |
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
#!/usr/bin/env ruby | |
# | |
# OMG THIS CODE IS SO UGLY | |
# but... | |
# IT WORKS!! | |
# | |
# Hacked together by http://github.com/marcinbunsch | |
# | |
# This assumes the following: | |
# - That you're on a Mac |
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
# This file is responsible for configuring your application | |
# and its dependencies with the aid of the Mix.Config module. | |
# | |
# This configuration file is loaded before any dependency and | |
# is restricted to this project. | |
use Mix.Config | |
# Configures the namespace used by Phoenix generators | |
config :my_app, | |
app_namespace: MyApp |
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
segment = Segment::TwitterFollowers.create( | |
name: "Demo Twitter Followers Segment #{ timestamp }", | |
account: account, | |
client: client, | |
definition_data: "@nike\n" | |
) | |
VS |
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
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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
PG_OLD=9.1 | |
PG_NEW=9.4 | |
echo "deb http://apt.postgresql.org/pub/repos/apt/ `lsb_release -cs`-pgdg main" | sudo tee /etc/apt/sources.list.d/pgdg.list | |
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add - | |
sudo apt-get update | |
sudo apt-get install postgresql-$PG_NEW postgresql-server-dev-$PG_NEW postgresql-contrib-$PG_NEW -y | |
sudo su - postgres -c "psql template1 -p 5433 -c 'CREATE EXTENSION IF NOT EXISTS hstore;'" | |
sudo su - postgres -c "psql template1 -p 5433 -c 'CREATE EXTENSION IF NOT EXISTS \"uuid-ossp\";'" | |
sudo su - postgres -c "service postgresql stop" |
NewerOlder