Skip to content

Instantly share code, notes, and snippets.

View mathieutu's full-sized avatar
🚴

Mathieu TUDISCO mathieutu

🚴
View GitHub Profile
@xgp
xgp / Dockerfile
Last active April 23, 2024 13:01
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
@VassilisPallas
VassilisPallas / index.ts
Last active November 25, 2020 03:12
Equivalent to PHP function number_format in Javascript
const assert = require('assert');
const numberFormat = require('./numberFormat');
assert.strictEqual(
numberFormat(132323232320.321, 2, ',', '.'),
'132.323.232.320,32'
);
assert.strictEqual(
numberFormat(10.22),
'10.22'
@vladimirtsyupko
vladimirtsyupko / gist:10964772
Created April 17, 2014 08:32
Git force pull to overwrite local files
git fetch --all
git reset --hard origin/master
git pull origin master