Skip to content

Instantly share code, notes, and snippets.

View abdullahainun's full-sized avatar
🏠
Working from home

Ainun Abdullah abdullahainun

🏠
Working from home
View GitHub Profile
@sanchpet
sanchpet / alertmanager.yml
Last active June 5, 2025 01:57
Telegram message template for Alertmanager & how to add it to your receiver in alertmanager.yml
receivers:
- name: 'Default'
telegram_configs:
- bot_token: <token>
api_url: https://api.telegram.org
chat_id: <chat_id>
message_thread_id: <message_thread_id> # for supergroups with threads
parse_mode: 'HTML'
message: '{{ template "telegram.message". }}'
@amanjuman
amanjuman / sh.md
Last active March 14, 2025 09:34
Debian 12 Netplan.io

Install Packages

sudo apt install netplan.io openvswitch-switch

Configure Netplan

nano /etc/netplan/network.yaml
network:
Select range and block it in router.
Download Server
157.240.16.16:443
PORT - 443 eg: 99.83.180.80:443
99.83.180.89
75.2.18.40
Main Menu IP Range:
@Syed-Hassaan
Syed-Hassaan / GSP345 | Automating Infrastructure on Google Cloud with Terraform: Challenge Lab.txt
Created May 20, 2021 09:29
GSP345 | Automating Infrastructure on Google Cloud with Terraform: Challenge Lab
######################################################################################
## Automating Infrastructure on Google Cloud with Terraform: Challenge Lab # GSP345 ##
######################################################################################
====================== Setup : Create the configuration files ======================
Make the empty files and directories in Cloud Shell or the Cloud Shell Editor.
------------------------------------------------------------------------------------
touch main.tf
touch variables.tf
@guibranco
guibranco / Dockerfile
Last active May 6, 2025 05:37
Docker file for PHP 7.4 with Apache, MySQLi extension, GD2 and Apache mod_rewrite enabled
FROM php:7.4-apache
RUN apt-get update
RUN apt-get install --yes --force-yes cron g++ gettext libicu-dev openssl libc-client-dev libkrb5-dev libxml2-dev libfreetype6-dev libgd-dev libmcrypt-dev bzip2 libbz2-dev libtidy-dev libcurl4-openssl-dev libz-dev libmemcached-dev libxslt-dev
RUN a2enmod rewrite
RUN docker-php-ext-install mysqli
RUN docker-php-ext-enable mysqli
@ekoyudhi
ekoyudhi / gsp344_serverless-firebase-development-challenge-lab.sh
Created March 14, 2021 03:51
Serverless Firebase Development: Challenge Lab
gcloud config set project $(gcloud projects list --format='value(PROJECT_ID)' --filter='qwiklabs-gcp')
git clone https://github.com/rosera/pet-theory.git
# 1. Firestore Database Create
Go to Firestore > Select Naive Mode > Location: nam5 > Create Database
# 2. Firestore Database Populate
cd pet-theory/lab06/firebase-import-csv/solution
npm install
node index.js netflix_titles_original.csv

Mounting VirtualBox shared folders on an Ubuntu guest

This guide will walk you through the steps on how to setup a VirtualBox shared folder inside an Ubuntu VM that has been exported from an AWS EC2 instance.

Prerequisites

This guide assumes that you are using the following setup:

Initial Steps

@jarek-przygodzki
jarek-przygodzki / node_exporter-as-systemd-service.md
Last active April 25, 2025 13:23
Installing node_exporter as systemd serivice
sudo useradd --system --shell /bin/false node_exporter
curl -fsSL https://github.com/prometheus/node_exporter/releases/download/v1.3.1/node_exporter-1.3.1.linux-amd64.tar.gz \
  | sudo tar -zxvf - -C /usr/local/bin --strip-components=1 node_exporter-1.3.1.linux-amd64/node_exporter \
  && sudo chown node_exporter:node_exporter /usr/local/bin/node_exporter
@danielepolencic
danielepolencic / README.md
Last active October 27, 2024 08:34
Create 3 nodes Kubernetes cluster locally with Vagrant

3 Virtual Machines Kubernetes cluster

Dependencies

You should install VirtualBox and Vagrant before you start.

Creating the cluster

You should create a Vagrantfile in an empty directory with the following content:

@zodvik
zodvik / benchmark-commands.txt
Last active December 18, 2022 12:45
Kafka (1.0.0) Benchmark Commands
Producer
Setup
bin/kafka-topics.sh --zookeeper localhost:2181/kafka-local --create --topic test-rep-one --partitions 6 --replication-factor 1
bin/kafka-topics.sh --zookeeper localhost:2181/kafka-local --create --topic test-rep-two --partitions 6 --replication-factor 3
Single thread, no replication
bin/kafka-run-class.sh org.apache.kafka.tools.ProducerPerformance --print-metrics --topic test-rep-one --num-records 6000000 --throughput 100000 --record-size 100 --producer-props bootstrap.servers=kafka_host:9092 buffer.memory=67108864 batch.size=8196
Single-thread, async 3x replication