Skip to content

Instantly share code, notes, and snippets.


Devan devansvd

View GitHub Profile
View stuff.txt
Self Evaluation:
- Interested in improving in software field ?
- What you consider your areas of strength in coding.
- What parts you feel need to improve.
- Which areas you want to focus on ? list detailed specifics.
devansvd / complete-pipeline.yml
Last active Jan 8, 2021
gitlab ci docker build and push to private docker registry pipeline
View complete-pipeline.yml
# Ci pipeline to buid docker images
# and push to gitlab docker registry
# auto deploy as well
- build
image: docker:latest
stage: build
devansvd /
Last active Jul 11, 2020
List of My Experiments
devansvd /
Created Jun 26, 2020
Protect open backends with Openid/oauth with louketo-openid-proxy

Protect open backends with Openid/oauth with louketo-openid-proxy

louketo-openid-proxy -

Looks like client-id in the token aud is mandatory.

To add Keycloakadmin -> Client -> Mappers -> Create -> mapper type audience -> select client id

docker run --name louketo-openid-proxy -it -d \
  -p 8440:8440 \

Basic docker alpine setup

FROM node:12.18.0-alpine3.9

WORKDIR /usr/src/app

COPY . .

RUN apk --no-cache --virtual build-dependencies add \
    python \

Command to list

import os; [(os.path.dirname(file)[len('Packages/'):], sublime.decode_value(sublime.load_resource(file))['url']) for file in sublime.find_resources('package-metadata.json')]

import os; [(os.path.dirname(file)[len('Packages/'):]) for file in sublime.find_resources('package-metadata.json')]

Plugins Installed

['AutoFileName', 'AutoPEP8', 'BracketHighlighter', 'Dockerfile Syntax Highlighting', 'EditorConfig', 'Emmet', 'Generic Config', 'HTML5', 'MarkdownPreview', 'Night Owl', 'Package Control', 'Python 3', 'Sass', 'SideBarEnhancements', 'TOML', 'Vue Syntax Highlight', 'HTML-CSS-JS Prettify', 'JsPrettier', 'TypeScript']
devansvd / AesUtil.js
Created Jun 1, 2020 — forked from AndiDittrich/AesUtil.js
Node.js - AES Encryption/Decryption with AES-256-GCM using random Initialization Vector + Salt
View AesUtil.js
// AES Encryption/Decryption with AES-256-GCM using random Initialization Vector + Salt
// ----------------------------------------------------------------------------------------
// the encrypted datablock is base64 encoded for easy data exchange.
// if you have the option to store data binary save consider to remove the encoding to reduce storage size
// ----------------------------------------------------------------------------------------
// format of encrypted data - used by this example. not an official format
// +--------------------+-----------------------+----------------+----------------+
// | SALT | Initialization Vector | Auth Tag | Payload |
// | Used to derive key | AES GCM XOR Init | Data Integrity | Encrypted Data |
View shadow-dom.html
<!DOCTYPE html>
<html lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<body style="text-align: center;">
View cloudSettings
devansvd /
Last active Jun 9, 2020
My standard prettier formatter configuration

Auto format staged files before commit, Prettier is the best formatter available now, but it formats html ugly. Using beautify to formatter only html, others prettier will handle

Note: use common print width 100 for both beautify and prettier

Install devDependencies

npm i -D husky prettier js-beautify lint-staged