Conversation
Currently, the startup messages printed by pasta are discarded, because `logWriter` is passed to `pasta.NewParentDriver` but never used. This commit forwards them to `logWriter` so that they appear in the debug log, like the slirp4netns driver does. After applying this commit, the following log is shown with `--debug`: ```bash DEBU[0000] [rootlesskit:parent] network/pasta: UNIX domain socket bound at /tmp/haytok/.pasta.sock DEBU[0000] [rootlesskit:parent] network/pasta: Configuration socket: /tmp/haytok/.pasta.sock DEBU[0000] [rootlesskit:parent] network/pasta: Template interface: dummy42 (IPv4), dummy42 (IPv6) DEBU[0000] [rootlesskit:parent] network/pasta: Namespace interface: tap0 DEBU[0000] [rootlesskit:parent] network/pasta: MAC: DEBU[0000] [rootlesskit:parent] network/pasta: host: 9a:55:9a:55:9a:55 DEBU[0000] [rootlesskit:parent] network/pasta: DHCP: DEBU[0000] [rootlesskit:parent] network/pasta: assign: 10.0.2.100 DEBU[0000] [rootlesskit:parent] network/pasta: mask: 255.255.255.0 DEBU[0000] [rootlesskit:parent] network/pasta: router: 10.0.2.2 DEBU[0000] [rootlesskit:parent] network/pasta: DNS: DEBU[0000] [rootlesskit:parent] network/pasta: 10.0.2.3 DEBU[0000] [rootlesskit:parent] network/pasta: DNS search list: DEBU[0000] [rootlesskit:parent] network/pasta: . DEBU[0000] [rootlesskit:parent] network/pasta: NDP/DHCPv6: DEBU[0000] [rootlesskit:parent] network/pasta: assign: fd00::100 DEBU[0000] [rootlesskit:parent] network/pasta: router: fd00::2 DEBU[0000] [rootlesskit:parent] network/pasta: our link-local: fe80::9cca:6ff:fe87:1ae1 DEBU[0000] [rootlesskit:parent] network/pasta: DNS search list: DEBU[0000] [rootlesskit:parent] network/pasta: . DEBU[0000] [rootlesskit:parent] network/pasta: Inbound forwarding rules (HOST): DEBU[0000] [rootlesskit:parent] network/pasta: Outbound forwarding rules (SPLICE): ``` Signed-off-by: Hayato Kiwata <dev@haytok.jp>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, the startup messages printed by pasta are discarded, because
logWriteris passed topasta.NewParentDriverbut never used.This commit forwards them to
logWriterso that they appear in the debug log, like the slirp4netns driver does.After applying this commit, the following log is shown with
--debug: