Skip to content

Instantly share code, notes, and snippets.

@dinnouti
dinnouti / unbound.conf
Created June 28, 2023 20:13
unbound configuration for ubuntu 22.04
server:
tls-cert-bundle: /etc/ssl/certs/ca-certificates.crt
qname-minimisation: yes
interface: eth0
access-control: 192.168.0.0/16 allow
logfile: "/var/log/unbound.log"
use-syslog: no
do-ip6: no
prefetch: yes
cache-max-ttl: 14400
@dinnouti
dinnouti / .aider.model.metadata.json
Last active May 24, 2025 19:00
Adding Amazon Nova and Claude 3 Models to Aider Chat
{
"bedrock/us.amazon.nova-micro-v1:0": {
"max_tokens": 4096,
"max_input_tokens": 300000,
"max_output_tokens": 4096,
"input_cost_per_token": 0.000000035,
"output_cost_per_token": 0.00000014,
"litellm_provider": "bedrock_converse",
"mode": "chat",
"supports_function_calling": true,
@dinnouti
dinnouti / delete-archive-from-output.sh
Created July 5, 2025 01:57
Delete non-empty Glacier using the inventory-retrieval
#!/bin/bash
# https://docs.aws.amazon.com/amazonglacier/latest/dev/deleting-vaults-cli.html
usage="Usage ${0} account-id vault-name get-job-output.json aws-profile"
if [[ -z ${1} ]]; then
echo "Missing the account-id"
echo ${usage}
exit 1
fi
@dinnouti
dinnouti / joke.sh
Created May 26, 2026 20:23
Get a joke in bash
#!/bin/bash
getAJoke() {
JOKES=$(curl -s --max-time 2 "https://v2.jokeapi.dev/joke/Programming?blacklistFlags=nsfw,religious,political,racist,sexist,explicit&format=txt&type=single" || true)
if [ "$JOKES" != "" ]; then
echo -e " - Until then, here's a joke for you:\n"
echo -e "$JOKES\n"
fi
}