Skip to repository content

tenant.openagents/omega

No repository description is available.

OpenAgents Git authority 2026-07-27T23:30:09.617Z Public web read
NIP-34 coordinate30617:7649603503856e5148d571eac2766b288a8ff1e9e35d380337a1d2b0015b4f92:omega
MaintainersHidden in public view
References2 branches · 1 tag
Read-only clonegit clone https://openagents.com/git/tenant.openagents/omega.git
Browse files

mitm-proxy.sh

31 lines · 939 B · shellscript
1#!/usr/bin/env bash
2
3set -euo pipefail
4
5if command -v docker >/dev/null 2>&1; then
6    ENGINE="docker"
7elif command -v podman >/dev/null 2>&1; then
8    ENGINE="podman"
9else
10    echo "Neither Docker nor Podman found. Please install one of them."
11    exit 1
12fi
13if [ ! -d ~/.mitmproxy ]; then
14    mkdir -p ~/.mitmproxy
15fi
16
17CONTAINER_ID="$(${ENGINE} run -d --rm -it -v ~/.mitmproxy:/home/mitmproxy/.mitmproxy -p 9876:8080 mitmproxy/mitmproxy mitmdump)"
18
19trap "${ENGINE} stop \"$CONTAINER_ID\" 1> /dev/null || true; exit 1" SIGINT
20
21echo "Add the root certificate created in ~/.mitmproxy to your certificate chain for HTTP"
22echo "on macOS:"
23echo "sudo security add-trusted-cert -d -p ssl -p basic -k /Library/Keychains/System.keychain ~/.mitmproxy/mitmproxy-ca-cert.pem"
24echo "Press enter to continue"
25read
26
27http_proxy=http://localhost:9876 cargo run
28
29# Clean up detached proxy after running
30${ENGINE} stop "${CONTAINER_ID}" 2>/dev/null || true
31
Served at tenant.openagents/omega Member data and write actions are omitted.