ALTER TABLE logs.trades CHANGE recentprice price int;
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
#!/bin/bash | |
# Description: Recursively moves and replaces conflicted Dropbox files keeping the newer one of each pair | |
# Usage: <script-name> - Shows what files would be moved and replaced but does not do any replacements | |
<script-name> replace - Performs file replacements | |
# Based on: http://mechanicalscribe.com/notes/fix-dropbox-conflicts-automatically/ | |
# Thx, http://stackoverflow.com/questions/20723868/batch-rename-dropbox-conflict-files |
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
.git | |
.gitignore | |
/doc | |
.yardoc | |
coverage | |
jsdoc | |
/tmp | |
/log | |
Dockerfile | |
Dockerfile.prod |
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
FROM ruby:2.3.1 | |
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs | |
# Configuring main directory | |
RUN mkdir -p /app_name | |
WORKDIR /app_name | |
# Setting env up | |
ENV RAILS_ENV='production' | |
ENV RAKE_ENV='production' |
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 is just a cheat sheet: | |
# On production | |
sudo -u postgres pg_dump database | gzip -9 > database.sql.gz | |
# On local | |
scp -C production:~/database.sql.gz | |
dropdb database && createdb database | |
gunzip < database.sql.gz | psql database |
I'm going to walk you through the steps for setting up a AWS Lambda to talk to the internet and a VPC. Let's dive in.
So it might be really unintuitive at first but lambda functions have three states.
- No VPC, where it can talk openly to the web, but can't talk to any of your AWS services.
- VPC, the default setting where the lambda function can talk to your AWS services but can't talk to the web.
- VPC with NAT, The best of both worlds, AWS services and web.
The easiest way to get the ClamAV package is using Homebrew
$ brew install clamav
Before trying to start the clamd
process, you'll need a copy of the ClamAV databases.
Create a freshclam.conf
file and configure as so
NewerOlder