kind: Secret
apiVersion: v1
metadata:
  name: wireguard-config
type: Opaque
stringData:
  wg0.conf: |
    [Interface]
    PrivateKey = iFSGFZK9NUjDmous7OX183llmqUt3gYe7Wy8edL2kUo=
    Address = 10.0.0.1/32
    PostUp = iptables -I OUTPUT ! -o %i -m mark ! --mark $(wg show %i fwmark) -m addrtype ! --dst-type LOCAL -j REJECT && iptables -A INPUT -p tcp --dport 80 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT && iptables -A OUTPUT -p tcp --sport 80 -m conntrack --ctstate ESTABLISHED -j ACCEPT
    PreDown = iptables -D OUTPUT ! -o %i -m mark ! --mark $(wg show %i fwmark) -m addrtype ! --dst-type LOCAL -j REJECT && iptables -D INPUT -p tcp --dport 80 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT && iptables -D OUTPUT -p tcp --sport 80 -m conntrack --ctstate ESTABLISHED -j ACCEPT

    [Peer]
    PublicKey = EM3YReoB2L+Ql7iT8gjRvQfLekJaKfZLMYsiDNtqaW8=
    AllowedIPs = 0.0.0.0/0
    Endpoint = 127.0.0.1:50000