Skip to content

Instantly share code, notes, and snippets.

@dasniko
dasniko / upgrade_keycloak_database_settings.md
Created May 10, 2023 05:06
Upgrade Keycloak Database #settings

Because of Arjuna timeout / closing the connection after 5 mins, setting following additional JAVA_OPTS might help:

-Dquarkus.transaction-manager.default-transaction-timeout=3600
-Dkeycloak.migration.batch-enabled=true
-Dkeycloak.migration.batch-size=1000

[guide] keycloak authentication for proxmox

How to setup Proxmox to use Keycloak as authentication realm.

Proxmox Setup

root@proxmox:/etc/pve# cat domains.cfg
pam: pam
        comment Linux PAM standard authentication
@xgp
xgp / Dockerfile
Last active April 23, 2025 11:17
Keycloak 17 example using JGroups JDBC_PING discovery protocol for Infinispan
FROM quay.io/keycloak/keycloak:17.0.0 as builder
ENV KC_METRICS_ENABLED=true
ENV KC_FEATURES=preview
ENV KC_DB=postgres
ENV KC_HTTP_RELATIVE_PATH=/auth
# specify the custom cache config file here
ENV KC_CACHE_CONFIG_FILE=cache-ispn-jdbc-ping.xml
# copy the custom cache config file into the keycloak conf dir
@lynsei
lynsei / .gitignore
Last active November 19, 2024 20:41
[cloud-init] #Ubuntu #Hard #CIS #hardened 20.04 #splunk #lynslang
node_modules
@hugefiver
hugefiver / set_proxy.ps1
Last active August 12, 2024 02:53
powershell set default proxy for `Invoke-WebRequest`
# set to system default proxy
[System.Net.WebRequest]::DefaultWebProxy = [System.Net.WebRequest]::GetSystemWebProxy()
[System.Net.WebRequest]::DefaultWebProxy.Credentials = [System.Net.CredentialCache]::DefaultNetworkCredentials
# or a custom one
[System.Net.WebRequest]::DefaultWebProxy = New-Object System.Net.WebProxy("http://localhost:8080")
# or use username and password auth
[System.Net.WebRequest]::DefaultWebProxy = New-Object System.Net.WebProxy("http://localhost:8080",$true)
[System.Net.WebRequest]::DefaultWebProxy.Credentials = New-Object System.Net.NetworkCredential($user, $passwd)
@kiler129
kiler129 / README.md
Last active May 6, 2025 16:02 — forked from seeker2921/ilo-console.sh
Run iLO remote console from shell

iLO Remote Console

This small script lets you start iLO Java-based console from shell.

But why not HTML5?

  • iLO 2/3 doesn't have HTML5 console
  • Mounting local (from the client computer) ISOs is PAINFULLY slow via HTML5 client

TL;DR

If you just start it, it will ask you for everything:

@mirajehossain
mirajehossain / ubuntu-server-hardening.md
Last active April 11, 2025 08:37
ubuntu-server-hardening checklist

Ubuntu-Server-Hardening

1. Secure Shared Memory

What is shared memory?

Shared memory is an efficient means of passing data between programs. Because two or more processes can use the same memory space, it has been discovered that, since shared memory is, by default, mounted as read/write, the /run/shm space can be easily exploited. That translates to a weakened state of security.

If you’re unaware, shared memory can be used in an attack against a running service. Because of this, you’ll want to secure that portion of system memory.

@kvnxiao
kvnxiao / awesome-selfhosted-sorted-by-stars.md
Last active May 14, 2025 11:32
awesome-selfhosted-sorted-by-stars.md

Awesome-Selfhosted

Awesome

Selfhosting is the process of locally hosting and managing applications instead of renting from SaaS providers.

This is a list of Free Software network services and web applications which can be hosted locally. Non-Free software is listed on the Non-Free page.

See Contributing.

@itSQualL
itSQualL / postgres_dumps.md
Last active April 10, 2025 14:51
How to backup and restore postgres from docker

Docker & PostgreSQL

How to backup PostgreSQL database from Docker container

  1. Go to the directory with docker-compose file.

  2. Execute the next command to get db dump (note that the next command is an example for actual docker-compose config):

docker-compose run postgres pg_dump -h postgres -U postgres db_development > db_development.dump
@chrisswanda
chrisswanda / WireGuard_Setup.txt
Last active May 8, 2025 19:21
Stupid simple setting up WireGuard - Server and multiple peers
Install WireGuard via whatever package manager you use. For me, I use apt.
$ sudo add-apt-repository ppa:wireguard/wireguard
$ sudo apt-get update
$ sudo apt-get install wireguard
MacOS
$ brew install wireguard-tools
Generate key your key pairs. The key pairs are just that, key pairs. They can be