Skip to content

Instantly share code, notes, and snippets.

View TaQuanMinhLong's full-sized avatar
🎹
On The Stage

Tạ Quan Minh Long TaQuanMinhLong

🎹
On The Stage
  • MM Mega Market Vietnam
  • Ho Chi Minh City
  • 13:04 (UTC +07:00)
View GitHub Profile
# Setting proto build with ts-proto
# Proto dir: $PROJECT_ROOT/proto/your_proto_file.proto
protoc \
--plugin=./node_modules/.bin/protoc-gen-ts_proto \
--ts_proto_opt=esModuleInterop=true \
--ts_proto_opt=importSuffix=.js \
--ts_proto_opt=outputServices=grpc-js \
--ts_proto_opt=env=node \
--ts_proto_out=./packages/proto/src \
@TaQuanMinhLong
TaQuanMinhLong / kafka.docker-compose.yaml
Last active February 8, 2024 10:11
Kafka Docker Setup
version: '3.8'
services:
kafka:
container_name: kafka
image: bitnami/kafka
networks:
- kafka.net
restart: unless-stopped
ports:
- "9092:9092"
@TaQuanMinhLong
TaQuanMinhLong / update_golang.nu
Last active June 8, 2024 10:08
Update golang version using Nushell script
# Config
const INSTALL_DIR = "/usr/local"
const DL_URL = "https://go.dev/dl/"
let num_threads = sys | get cpu | length
let GO_ROOT = $INSTALL_DIR | path join go
let GO_BIN = $GO_ROOT | path join bin
let TMP_DIR = $env.PWD | path join go_dl_tmp
let ADD_TO_PATH = $"add_to_path ($GO_BIN)"
# let ADD_TO_PATH = $"$env.PATH = \(if ($GO_BIN) in $env.PATH { $env.PATH } else { \($env.PATH | split row \(char esep) | append ($GO_BIN)) })"
@TaQuanMinhLong
TaQuanMinhLong / upgrade_postgres.md
Last active September 28, 2024 04:00
Upgrade postgres version from docker-compose

Make sure postgres is running at the current old version

image: postgres:16-alpine

Pull new image if needed

docker pull postgres:17-alpine