Skip to content

Instantly share code, notes, and snippets.

View sandyverden's full-sized avatar

Sandi Budiman sandyverden

View GitHub Profile
@sandyverden
sandyverden / Android_Emulator_AWS_EC2_ARM64_2022.txt
Created April 25, 2024 08:45 — forked from atyachin/Android_Emulator_AWS_EC2_ARM64_2022.txt
Running headless android emulator on AWS EC2 Ubuntu instance (ARM64 / aarch64) - 2022
Android Emulator (ARM64) on EC2 - 2022
---------------------------------------
1. Launch EC2 ARM based Instance (a1.metal / a1.2xlarge): (16 Gb RAM, 32Gb Disk), Ubuntu Server 22.04 LTS (HVM) ARM x64
2. sudo apt update && sudo apt upgrade
3. sudo apt install default-jdk python3-pip repo python-is-python3 unzip libpcre2-dev adb
4. wget https://dl.google.com/android/repository/commandlinetools-linux-8512546_latest.zip
5. unzip commandlinetools-linux-8512546_latest.zip -d android-sdk
6. sudo mv android-sdk /opt/
7. mkdir /opt/android-sdk/cmdline-tools/latest
8. mv /opt/android-sdk/cmdline-tools/* /opt/android-sdk/cmdline-tools/latest (ignore the error)
@sandyverden
sandyverden / iftop.sh
Created September 13, 2023 04:27 — forked from lemonlatte/iftop.sh
Amazon Linux install iftop
amazon-linux-extras install epel -y
yum-config-manager --enable epel
yum install iftop
@sandyverden
sandyverden / Jenkinsfile.groovy
Created April 8, 2020 01:33 — forked from mattiasholmqvist/Jenkinsfile.groovy
Example Jenkinsfile for Kubernetes-based CI docker builds
podTemplate(label: 'builder',
containers: [
containerTemplate(name: 'jnlp', image: 'larribas/jenkins-jnlp-slave-with-ssh:1.0.0', args: '${computer.jnlpmac} ${computer.name}'),
containerTemplate(name: 'docker', image: 'docker', command: 'cat', ttyEnabled: true),
containerTemplate(name: 'kubectl', image: 'ceroic/kubectl', command: 'cat', ttyEnabled: true),
containerTemplate(name: 'maven', image: 'maven:3.3.9-jdk-8-alpine', ttyEnabled: true, command: 'cat')
],
volumes: [
hostPathVolume(hostPath: '/var/run/docker.sock', mountPath: '/var/run/docker.sock'),
secretVolume(secretName: 'maven-settings', mountPath: '/root/.m2'),
@sandyverden
sandyverden / aws-workshop.md
Created March 13, 2020 05:38 — forked from ejlp12/aws-workshop.md
AWS Workshop
@sandyverden
sandyverden / POSTMORTEM.md
Created June 28, 2019 03:07 — forked from voxxit/POSTMORTEM.md
Example/outline of a postmortem to be conducted after a site outage/incident

POSTMORTEM: “Event Title Here”

Issue Summary

This should be a short (4-5 sentences) blurb which succinctly describes the event. At the very least, it should include:

  • the duration (with start & end times in the U.S. Pacific time zone):

…which lasted for roughly 10 minutes between 9:02PM and 9:12PM Pacific…

  • the impact to our users:
@sandyverden
sandyverden / RUNBOOK.md
Created June 28, 2019 03:05 — forked from voxxit/RUNBOOK.md
Example of a solid run book/operations manual

Run Book / Operations Manual

  1. Table of Contents
  2. System Overview
    • Service Overview
    • Contributing Applications, Daemons, and Windows Services
    • Hours of Operation
    • Execution Design
    • Infrastructure and Network Design
    • Resilience, Fault Tolerance and High-Availability
@sandyverden
sandyverden / delete_old_filebeat_indices.sh
Created June 17, 2019 08:49 — forked from ricsiga/delete_old_filebeat_indices.sh
delete old filebeat indices from elasticsearch
#!/bin/bash
index=$(date --date='14 days ago' +%Y.%m.%d)
curl -s -XDELETE "http://localhost:9200/filebeat-$index?pretty"

Keybase proof

I hereby claim:

  • I am sandyverden on github.
  • I am sandyverden (https://keybase.io/sandyverden) on keybase.
  • I have a public key ASCuWpPOWxfUi7-dItECQBey2HeAaZz8VEF2OfrvA5rRoAo

To claim this, I am signing this object:

@sandyverden
sandyverden / read-access.sql
Created January 10, 2019 06:41 — forked from oinopion/read-access.sql
How to create read only user in PostgreSQL
-- Create a group
CREATE ROLE readaccess;
-- Grant access to existing tables
GRANT USAGE ON SCHEMA public TO readaccess;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess;
-- Grant access to future tables
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess;