... or Why Pipelining Is Not That Easy
Golang Concurrency Patterns for brave and smart.
By @kachayev
... or Why Pipelining Is Not That Easy
Golang Concurrency Patterns for brave and smart.
By @kachayev
| Your monthly notice to go through and disconnect unused applications across various services. | |
| Twitter: https://twitter.com/settings/applications | |
| Dropbox: https://www.dropbox.com/account/connected_apps | |
| Facebook: https://www.facebook.com/settings?tab=applications | |
| Google Apps: https://security.google.com/settings/security/permissions?pli=1 | |
| Google Ads: http://www.google.com/ads/preferences | |
| Google Account: https://security.google.com/settings/security/secureaccount | |
| Foursquare: https://foursquare.com/settings/connections | |
| Instagram: https://instagram.com/accounts/manage_access |
| #!/bin/sh | |
| # | |
| # Query a property from the terminal, e.g. background color. | |
| # | |
| # XTerm Operating System Commands | |
| # "ESC ] Ps;Pt ST" | |
| oldstty=$(stty -g) | |
| # What to query? |
| defmodule HttpRequester do | |
| use GenServer | |
| def start_link(_) do | |
| GenServer.start_link(__MODULE__, nil, []) | |
| end | |
| def fetch(server, url) do | |
| # Don't use cast: http://blog.elixirsips.com/2014/07/16/errata-dont-use-cast-in-a-poolboy-transaction/ | |
| timeout_ms = 10_000 |
| # On the phoenix node | |
| # if production mode | |
| MIX_ENV=prod PORT=4001 elixir --name phoenix@127.0.0.1 --cookie 123 --erl "-kernel inet_dist_listen_min 9001 inet_dist_listen_m 9001" -pa _build/prod/consolidated -S mix phoenix.server | |
| # if debug mode | |
| elixir --name phoenix@127.0.0.1 --cookie 123 --erl "-kernel inet_dist_listen_min 9001 inet_dist_listen_m 9001" -S mix phoenix.server | |
| # On the observing node | |
| # Terminal 1, start SSH tunnel | |
| ssh -N -L 9001:localhost:9001 -L 4369:localhost:4369 pi@192.168.1.31 |
| %Plug.Conn{ | |
| adapter: {Plug.Adapters.Cowboy.Conn, :...}, | |
| assigns: %{ | |
| my_assigns: "here" | |
| }, | |
| before_send: [ | |
| #Function<7.125546534/1 in Phoenix.Controller.fetch_flash/2>, | |
| #Function<1.127904613/1 in Plug.Session.before_send/2>, | |
| #Function<1.43511252/1 in Plug.Logger.call/2>, | |
| #Function<0.70322810/1 in Phoenix.LiveReloader.before_send_inject_reloader/1> |
Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...
// see: https://github.com/chadoe/docker-cleanup-volumes
$ docker volume rm $(docker volume ls -qf dangling=true)
$ docker volume ls -qf dangling=true | xargs -r docker volume rm
| sns.publish({ | |
| TargetArn: device.arn, | |
| MessageStructure: 'json', | |
| Message: JSON.stringify({ | |
| default: 'you will never see this muah!', | |
| APNS_SANDBOX: JSON.stringify({ | |
| aps: { | |
| 'alert': '', | |
| 'content-available': 1 | |
| }, |
| -- Create a group | |
| CREATE ROLE readaccess; | |
| -- Grant access to existing tables | |
| GRANT USAGE ON SCHEMA public TO readaccess; | |
| GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
| -- Grant access to future tables | |
| ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; |
If you're aiming for a seamless Arch Linux installation in UEFI mode, follow along as this guide will walk you through the process step by step. We'll be using LUKS (Linux Unified Key Setup) and LVM (Logical Volume Manager) partitions on LUKS to achieve full disk encryption.
Note: I have updated this doc for UEFI mode. For those with BIOS/MBR systems, you can refer to the previous version, but keep in mind that it might be outdated and no longer accurate.
If you're only interested in installing Linux and not setting up dual boot with Windows, feel free to skip the Windows-related sections.