The easiest way to do it is from inside the container; you can intercept and print requests between nginx and Discourse by entering the container and running:
apt-get update && apt-get -y install scapy
scapy
# at the scapy prompt, paste in:
class Callback:
def __init__(self):
self.last = None
def prn(self, p):
if p != self.last: # pcaps on lo capture twice
self.last = p
p.hide_defaults()
print(repr(p)) # this line prints the packet, keep it or leave it
if scapy.packet.Raw in p.layers():
try:
print(p.load.decode())
except:
print(p.load)
sniff(filter="port 3000", iface="lo", prn=Callback().prn)