Skip to content

Instantly share code, notes, and snippets.

@HikariKnight
HikariKnight / proxmox-nginx-subdir-proxy.md
Last active April 26, 2024 03:38
proxmox nginx proxy subdirectory

So I have spent my last 4 days to try get proxmox working with an nginx proxy. Due to how proxmox is built up I had to get clever with some rewrite, break some nginx rules and spend sleepless nights awake to try figure this out (to be honest I am no genius on web servers as I rarely have to touch them). Plus it seems like nobody (from my googling) had managed to set proxmox up to work behind a proxied subdir, understandably so as some of the html generated uses absolute paths for sources instead of relative paths and you need to deal with that.

This is the proxmox.conf file i ended up making (Replace all instances of pve.local:8006 with your internal proxmox ip and port) And replace publicwebsite.com with your website domain

NOTE: THIS IS FOR PVE6 and I have no plans to fix for PVE7 as I do not need it behind a reverse proxy anymore.

Actually, it's a guide to setup docker macvlan network and it can be used to attach static ip to container on public/local network.

  1. Create docker public network:
docker network create -d macvlan --subnet=$SUBNET --gateway=$GATEWAY_IP -o parent=eth0 public

Where:
$SUBNET - your public network subnet
$GATEWAY_IP - your public network gateway

@fntlnz
fntlnz / self-signed-certificate-with-custom-ca.md
Last active May 17, 2024 07:59
Self Signed Certificate with Custom Root CA

Create Root CA (Done once)

Create Root Key

Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!

openssl genrsa -des3 -out rootCA.key 4096
@gear11
gear11 / main.py
Created December 17, 2013 14:54
Simple Python proxy server based on Flask and Requests. See: http:/python-proxy-server/gear11.com/2013/12/python-proxy-server/
"""
A simple proxy server. Usage:
http://hostname:port/p/(URL to be proxied, minus protocol)
For example:
http://localhost:8080/p/www.google.com
"""