Skip to content

Instantly share code, notes, and snippets.

View snandam's full-sized avatar

Sanjeev Nithyanandam snandam

  • Vancouver, BC
  • 23:49 (UTC -07:00)
View GitHub Profile
@snandam
snandam / secret_sharing_using_age.md
Last active April 7, 2026 17:51
Sharing Secrets using Age

Secret sharing using age

age is a simple, modern file encryption tool for sharing secrets via public-key encryption.

Install

macOS

brew install age
@snandam
snandam / Mange_Instances_README.md
Last active August 4, 2025 22:55
Create, manage ec2 instances created from an AMI into a VPC

EC2 Management Scripts

Two bash scripts for creating and managing AWS EC2 instances with automatic tagging and lifecycle management.

Scripts Overview

create_ec2_instances.sh

Creates multiple EC2 instances from a specified AMI with automatic tagging for project organization. Features:

  • Validates AWS configuration and AMI availability
  • Creates instances with consistent tagging (Project, Environment, CreatedBy, etc.)

Comprehensive Security Analysis Prompt Template

Use Case: Complete security audit of any software application with focus on privacy, data handling, and verification of marketing claims

Key Principle: Never trust claims without code evidence - "Trust but verify" through systematic analysis

🎯 MASTER PROMPT

I need you to perform a comprehensive security analysis of this codebase. I'm considering using this application but want to verify it's actually secure before trusting it with sensitive data.
@snandam
snandam / gist:b15defcc426367224a1de4cb54c2ba15
Last active July 21, 2025 17:12
Add aws mcp servers to claude code
claude mcp add aws-core \
-e FASTMCP_LOG_LEVEL=ERROR \
-- uvx "awslabs.core-mcp-server@latest"
claude mcp add aws-docs \
-e FASTMCP_LOG_LEVEL=ERROR \
-- uvx "awslabs.aws-documentation-mcp-server@latest"
claude mcp add aws-terraform \
@snandam
snandam / azurevm-template-ui.json
Last active March 15, 2025 01:00
azure-vm-template
{
"$schema": "https://schema.management.azure.com/schemas/0.1.2-preview/CreateUIDefinition.MultiVm.json#",
"handler": "Microsoft.Azure.CreateUIDef",
"version": "0.1.2-preview",
"parameters": {
"basics": [
{
"name": "vmName",
"type": "Microsoft.Common.TextBox",
"label": "Virtual Machine Name",
@snandam
snandam / aws_check_instance_availability.sh
Last active March 15, 2024 16:33
Identify AWS regions a particular instance type is available
####################
# IAM user need to have "ec2:DescribeInstanceTypeOfferings" permission to be able to run this
####################
#!/bin/bash
instance_type=g5g.2xlarge
echo "Region $instance_type Availability"
echo "------ -------------------------"

Keybase proof

I hereby claim:

  • I am snandam on github.
  • I am askjeev (https://keybase.io/askjeev) on keybase.
  • I have a public key ASDNzb1dsMqfClN6vkTVa7TycNTVHLaFjt_jSD1B0HsCIQo

To claim this, I am signing this object:

@snandam
snandam / ec2.tf
Last active November 15, 2022 19:43
Terraform - Bootstrap ec2 machine with ansible, copy scripts and run playbook
#--------------------------------------------------------------
# Create an EC2 machine, bootstrap with ansible
#
resource "aws_instance" "ec2-linux" {
ami = "ami-a4c7edb2"
vpc_security_group_ids = ["${aws_security_group.allow-all-test-sg.id}"]
key_name = "${var.private_ssh_key}"
instance_type = "t2.nano"
@snandam
snandam / get-latest-ami.sh
Last active August 29, 2017 18:40
Search for latest AWS AMI
#!/bin/bash
aws ec2 \
--region us-east-1 describe-images \
--filters \
'Name=architecture,Values=x86_64' \
'Name=root-device-type,Values=ebs' \
'Name=state,Values=available' \
'Name=virtualization-type,Values=hvm' \
'Name=image-type,Values=machine' \
# For more information on configuration, see:
# * Official English Documentation: http://nginx.org/en/docs/
# * Official Russian Documentation: http://nginx.org/ru/docs/
user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /var/run/nginx.pid;
# Load dynamic modules. See /usr/share/nginx/README.dynamic.