Effective total cost: $3–5/mo
Decide on an EC2 instance type:
- At AWS Console → EC2 → Instance Types, filter for ≥1 GB RAM and sort by price.
- t4g.micro is lowest.
# .github/workflows/publish.yml | |
name: Generate a build and push to another branch | |
on: | |
push: | |
branches: | |
- master # Remove this line if your primary branch is "main" | |
- main # Remove this line if your primary branch is "master" | |
jobs: |
// | |
// Author: Jonathan Blow | |
// Version: 1 | |
// Date: 31 August, 2018 | |
// | |
// This code is released under the MIT license, which you can find at | |
// | |
// https://opensource.org/licenses/MIT | |
// | |
// |
# prerequisites: | |
## install software | |
apt install mariadb-server libmariadbclient-dev sqlite3 | |
## install mysqlclient in virtualenv | |
su -c 'homeassistant/bin/pip3 install mysqlclient --upgrade' -l homeassistant | |
## create database | |
mysql -e 'CREATE SCHEMA IF NOT EXISTS `hass_db` DEFAULT CHARACTER SET utf8' | |
## create user (use a safe password please) | |
mysql -e "CREATE USER 'hass_user'@'localhost' IDENTIFIED BY 'hass_pw'" | |
mysql -e "GRANT ALL PRIVILEGES ON hass_db.* TO 'hass_user'@'localhost'" |
*update: TBC, but this new might affect how easy it is to use this technique past August 2024: Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August
This gist, based in part on a gist by Brian Hartvigsen, allows you to export from Authy your TOTP tokens you have stored there.
Those can be "standard" 6-digits / 30 secs tokens, or Authy's own version, the 7-digits / 10 secs tokens.
<?php | |
class Example extends SourcePluginBase { | |
public function prepareRow(Row $row) { | |
parent::prepareRow($row); | |
// I do some data manipulation to end up with an array that looks like this, | |
// which I want to import into multi-value link field. | |
$links = [ |
#!/bin/sh | |
remove_dangling() { | |
echo "Removing dangling images ..." | |
docker rmi $(docker images -f dangling=true -q) | |
} | |
remove_stopped_containers() { | |
echo "Removing stopped containers ..." | |
docker rm $(docker ps -qa) |