Here be dragons. Use with extreme caution.
This script is designed to accept namespaces as a list of arguments and will perform a namespace child resource delete loop before terminating the namespace and any finalizers.
Just thought I'd put together some detail on deploying Tailscale using Docker and Portainer. These bits-and-pieces are available elsewhere, but not together, so hopefully this will save someone a bit of time if you'd like to add Tailscale to an existing Docker install:
Here's my annotated recommended docker-compose, to use with Portainer-Stacks. Note that I'm not using a pre-made Auth Key. I started that way, but realized it was very easy to simply check the Portainer log for the tailscaled container once the stack is running. In that log you'll see the standard Auth link that you can use to authorize the container. This way you don't need to create a key in advance, or create a reusable key that introduces a security risk:
version: '3.9'
services:
tailscale:
image: tailscale/tailscale
container_name: tailscaled
# variables.tf | |
variable "myapp_conf" { | |
type = map | |
} | |
# terraform.tfvars | |
myapp_conf = { | |
REPLICAS = 0 | |
LIMIT_CPU = "50m" | |
LIMIT_MEMORY = "96Mi" |
sudo systemctl unmask sleep.target suspend.target hibernate.target hybrid-sleep.target | |
sudo vim /etc/systemd/logind.conf | |
# Replace whatever values of following to "ignore" | |
HandleHibernateKey=ignore | |
HandleLidSwitch=ignore | |
HandleLidSwitchExternalPower=ignore | |
HandleLidSwitchDocked=ignore |
# Listed generated on 2021-08-07 at 3:45am EST | |
curl -s -X GET -H "Content-Type: application/json" \ | |
-H "Authorization: Bearer ${DIGITALOCEAN_ACCESS_TOKEN}" \ | |
"https://api.digitalocean.com/v2/images?page=1&per_page=100&type=distribution" \ | |
| jq '.images[].slug' | sort | |
"centos-7-x64" | |
"centos-8-x64" | |
"centos-stream-8-x64" | |
"debian-10-x64" |
#cloud-config | |
groups: | |
- docker | |
users: | |
- default | |
# the docker service account | |
- name: docker-service | |
groups: docker | |
package_upgrade: true | |
packages: |
const assert = require('assert')
const BLUEBIRD = require('bluebird')
const nameAsync1 = async (name) => name
const nameAsync2 = (name) => Promise.resolve(name)
const nameAsync3 = (name) => BLUEBIRD.resolve(name)
const nameSync = (name) => name
const isPromise1 = (value) => Promise.resolve(value) === value
I used to use NERD tree for quite a while, then switched to CtrlP for something a little more lightweight. My setup now includes zero file browser or tree view, and instead uses native Vim fuzzy search and auto-directory switching.
There is a super sweet feature in Vim whereby you can fuzzy find your files using **/*
, e.g.:
:vs **/*<partial file name><Tab>
sentry
SENTRY_SECRET_KEY
to random 32 char stringdocker-compose up -d
docker-compose exec sentry sentry upgrade
to setup database and create admin userdocker-compose exec sentry pip install sentry-slack
if you want slack plugin, it can be done laterdocker-compose restart sentry
9000