Skip to content

Instantly share code, notes, and snippets.

# https://suno.com/song/8386f47c-7f35-4304-8a75-118c07f68b8a
[Verse]
Je marche dans la rue
Feeling kind of blue
I need some poutine
C'est quoi le menu?
Cheese curds
Gravy
Fries stacked high
@chwaee
chwaee / gist:efdb3c4c499d26822b2d7c3ed7610c62
Created October 4, 2023 05:47
K8s Nginx ingress controller updates for middleware logging service
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: my-app-ingress
annotations:
# Add annotations specific to your ingress controller, if any
nginx.ingress.kubernetes.io/rewrite-target: /
spec:
rules:
- host: myapp.example.com # Your domain
@chwaee
chwaee / gist:37fe9b22c65e6d8e30345aba067fdf4a
Created October 4, 2023 05:45
Node.js with express middleware for K8s nginx ingress controller sidecar
const express = require('express');
const app = express();
const axios = require('axios');
const PORT = 3000;
const TARGET_URL = 'http://main-app-service:8080'; // Replace with your main application's service URL
app.use(express.json()); // for parsing application/json
// Middleware to log request body
app.use((req, res, next) => {