Example on how to run locally an AWS Lambda via API Gateway using localstack.
Based on...
Example on how to run locally an AWS Lambda via API Gateway using localstack.
Based on...
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "log" | |
| "net/http" | |
| "strings" | |
| "time" |
| This demonstrates how to make client side certificates with go | |
| First generate the certificates with | |
| ./makecert.sh test@test.com | |
| Run the server in one terminal | |
| go run server.go |
| #This isn't very secure, but its for demo purposes | |
| docker run --name postgres -e POSTGRES_PASSWORD=password -d -p 54320:5432 \ | |
| -v $(pwd)/postgresql.conf:/srv/postgresql.conf \ | |
| -v $(pwd)/server.crt:/srv/server.crt \ | |
| -v $(pwd)/server.key:/srv/server.key \ | |
| -v $(pwd)/reconfigure_postgres.sh:/docker-entrypoint-initdb.d/reconfigure_postgres.sh \ | |
| postgres:9.5 |
| global | |
| chroot /var/lib/haproxy | |
| crt-base /etc/pki/tls/certs | |
| daemon | |
| group haproxy | |
| log 127.0.0.1 local0 | |
| maxconn 2000 | |
| pidfile /var/run/haproxy.pid | |
| stats socket /var/lib/haproxy/stats | |
| tune.ssl.default-dh-param 2048 |
| #!/bin/bash | |
| # Run as root or sudo the commands that need it as you go. | |
| # brew version 0.9.5 | |
| # Mac OS X 10.10.1 | |
| # A little bit changed version of this: | |
| # http://stackoverflow.com/questions/19538118/osx-mavericks-bind-no-longer-installed-how-to-get-local-dns-server-working |
When using directives, you often need to pass parameters to the directive. This can be done in several ways. The first 3 can be used whether scope is true or false. This is still a WIP, so validate for yourself.
Raw Attribute Strings
<div my-directive="some string" another-param="another string"></div>(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
| [alias] | |
| a = add . | |
| ai = add -i | |
| ac = !git add . && git commit -am | |
| ############# | |
| ap = apply | |
| as = apply --stat | |
| ############# | |
| ama = am --abort | |
| amr = am --resolved |
If you use git on the command-line, you'll eventually find yourself wanting aliases for your most commonly-used commands. It's incredibly useful to be able to explore your repos with only a few keystrokes that eventually get hardcoded into muscle memory.
Some people don't add aliases because they don't want to have to adjust to not having them on a remote server. Personally, I find that having aliases doesn't mean I that forget the underlying commands, and aliases provide such a massive improvement to my workflow that it would be crazy not to have them.
The simplest way to add an alias for a specific git command is to use a standard bash alias.
# .bashrc