Skip to content

Instantly share code, notes, and snippets.

View bkrajendra's full-sized avatar
🎯
Focusing

Rajendra bkrajendra

🎯
Focusing
View GitHub Profile
#include <DHT.h>
#define DHTPIN 15
#define DHTTYPE DHT22
DHT dht(DHTPIN, DHTTYPE);
void setup() {
Serial.begin(115200);
dht.begin();
}
// blink.ino
#define LED 2
int n = 0;
void setup() {
Serial.begin(115200);
pinMode(LED, OUTPUT);
}
void loop() {
@bkrajendra
bkrajendra / README.md
Last active April 26, 2026 08:43
SailPoint JIT Access POC

Workflow

User → LDAP/AD group → Linux group → sudo / access policy

Creat a LDAP

docker run -d \
  --name ldap \
  -p 389:389 \
 -e LDAP_ORGANISATION="corp" \
@bkrajendra
bkrajendra / llm-wiki.md
Created April 7, 2026 18:12 — forked from karpathy/llm-wiki.md
llm-wiki

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.

@bkrajendra
bkrajendra / singleton.ts
Created January 10, 2026 18:31
singleton
class ConfigService {
private static instance: ConfigService;
private config = { apiUrl: 'https://api.example.com' };
private constructor() {} // // Private constructor prevents direct instantiation
static getInstance(): ConfigService {
if (!ConfigService.instance) {
ConfigService.instance = new ConfigService();
}
@bkrajendra
bkrajendra / install-cloudflared.md
Last active October 5, 2025 18:07 — forked from sarkrui/install-cloudflared.md
Install Cloudflared on Alpine Linux

Cloudflared Setup Guide on Raspberry Pi with Home Assistant

This guide will walk you through setting up Cloudflared on your system.

Pre-Requisites

You need to have administrative (sudo) access to your system.

Here are the steps to install Cloudflared.

@bkrajendra
bkrajendra / deploy.yaml
Created October 28, 2024 05:18
Apache Deployment
apiVersion: apps/v1
kind: Deployment
metadata:
name: apache-server
labels:
app: apache-server
spec:
replicas: 1
selector:
matchLabels:
@bkrajendra
bkrajendra / cleanupUnusedWorkspaceInSlaves.groovy
Last active March 30, 2026 09:35 — forked from ceilfors/cleanupUnusedWorkspaceInSlaves.groovy
When you delete jobs in Jenkins, the corresponding workspaces in the build slaves won't be deleted automatically. This Jenkins script will go to each slave and check if the jobs are already deleted in Jenkins master and delete the workspace.
import com.cloudbees.hudson.plugins.folder.Folder
import hudson.FilePath
import jenkins.model.Jenkins
def boolean isFolder(String name) {
def item = Jenkins.instance.getItemByFullName(name)
return item instanceof Folder
}
def deleteUnusedWorkspace(FilePath root, String path, Boolean dryRun) {
@bkrajendra
bkrajendra / install-docker.md
Last active July 30, 2023 07:17 — forked from npearce/install-docker.md
Amazon Linux 2 - install docker & docker-compose using 'sudo amazon-linux-extras' command
@bkrajendra
bkrajendra / merge_properties.js
Created January 14, 2023 04:23
Application property processor
// Simple appproach for merging with subset of properties from json oject.
// Default Properties
const default_rolestudio = {
portal_name: 'Role Studio',
rolename_maxwidth: 200,
nested_property1: {value1: 30, value2: 20},
nested_property2: {value1: 30, value2: 20}
};
// Custom Properties