Skip to content

Instantly share code, notes, and snippets.

View RaveNoX's full-sized avatar
🔍
Looking for new challenges

Artur Kraev RaveNoX

🔍
Looking for new challenges
View GitHub Profile
@strarsis
strarsis / howto.md
Last active April 8, 2024 04:34
KeeAgent (for KeePass) on Bash on Windows / WSL (2)

Update (March 2023) (Last checked: March 2024)

Side note: The latest edge build of KeeAgent plugin offers an option for creating a WSL compatible socket. This would be very handy. I already tried to use that socket, but the socket file is currently empty and ssh inside WSL 2 is unable to use it. This appears to be a very new, unreleased and unstable feature. I will follow the development of it and when it finally works (well, for me) I will update this HOWTO. But until then, please use the proven wsl-ssh-agent/npiperelay.exe approach below.

Thanks to the instructions for WSL 2 of the wsl-ssh-agent project, KeeAgent works great in WSL 2 now: https://github.com/rupor-github/wsl-ssh-agent#wsl-2-compatibility The approach uses minimal and well maintained tools.

Mini-changelog

  • (16.03.2024) Add: Ensure 7z and wslvar being available (thanks @johnzielk
@ducas
ducas / increase-replication-factor.js
Last active November 8, 2021 14:42
Increase Replication Factor for Kafka Topics
/*
* This script reads the existing partition assignments in JSON (exported using kafka-reassign-partitions.sh) and generates
* the appropriate reassignment JSON file for input to kafka-reassign-partitions.sh.
*
*/
var usage = `
Usage: node increase-replication-factory.js (brokers) (replication factor) (current assignment file) (output file) [-f]
* brokers: comma separated list of brokers
* replication factor: the new replication factor to use
@ikbear
ikbear / idle.sh
Last active April 18, 2021 10:00
Docker image entrypoint idle script
#!/bin/bash
echo "This is a idle script (infinite loop) to keep container running."
echo "Please replace this script."
cleanup ()
{
kill -s SIGTERM $!
exit 0
}