We need to generate secret key for development environment.
mix phoenix.gen.secret
# ednkXywWll1d2svDEpbA39R5kfkc9l96j0+u7A8MgKM+pbwbeDsuYB8MP2WUW1hf
Let's generate User model and controller.
substitutions: | |
device: optolink | |
name: Optolink | |
esphome: | |
name: ${device} | |
platform: ESP32 | |
board: nodemcu-32s | |
includes: | |
- optolink.hpp |
#!/sbin/openrc-run | |
: ${MOSQUITTO_USER:=mosquitto} | |
: ${MOSQUITTO_GROUP:=mqtt} | |
: ${MOSQUITTO_CONF:=/etc/mosquitto/mosquitto.conf} | |
: ${MOSQUITTO_PIDDIR:=/run/mosquitto} | |
: ${MOSQUITTO_PIDFILE:=${MOSQUITTO_PIDDIR}/${SVCNAME}.pid} | |
: ${MOSQUITTO_LOGDIR:=/var/log/mosquitto} | |
: ${MOSQUITTO_PERSISTDIR:=/var/lib/mosquitto} | |
: ${MOSQUITTO_BINARY:=/usr/sbin/mosquitto} |
# import config. | |
# You can change the default config with `make cnf="config_special.env" build` | |
cnf ?= config.env | |
include $(cnf) | |
export $(shell sed 's/=.*//' $(cnf)) | |
# import deploy config | |
# You can change the default deploy config with `make cnf="deploy_special.env" release` | |
dpl ?= deploy.env | |
include $(dpl) |
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.
tell application "Spotlight" to inject SIMBL into Snow Leopard
openssl genrsa 2048 > host.key | |
openssl req -new -x509 -nodes -sha1 -days 3650 -key host.key > host.cert | |
#[enter *.localhost.dev for the Common Name] | |
openssl x509 -noout -fingerprint -text < host.cert > host.info | |
cat host.cert host.key > host.pem | |
Trust cert | |
sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain host.cert |
If you're like me you have a dir like ~/Workspace/Github
where all your git repos live. I often find myself making a change in a repo, getting side tracked and ending up in another repo, or off doing something else all together. After a while I end up with several repos with modifications. This script helps me pick up where I left off by checking the status of all my repos, instead of having to check each one individually.
Usage:
git-status [directory]
This will run git status
on each repo under the directory specified. If called with no directory provided it will default to the current directory.