-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for TFTP single port mode #14
Conversation
Use %s instead of %w for non-fmt.Errorf() calls.
Upgrade the pin/tftp package to the v3 release. This provides single port mode. Refactor the TFTP server plugin wrapper to use a struct with settings for port, address, etc. Convert several constants embedded in code to actual constants. Add a single port mode argument to TFTP server.
Originally in OP: Can we shove arbitary objects under the plugin keys? Something like:
would be a lot more flexible regarding defaults, and would be easier to parse into a matching struct. Sticking with the positionals for now for a somewhat less breaking change. No, sadly we cannot: the We could consider KV pairs, like |
I like these changes and I think you're onto something with the key-value layout for arguments. I think coresmd would be a lot easier to understand and configure that way. I would be interested in hearing what others think on that. Could you update the example config file to document these changes? |
@synackd example config updated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Add support for TFTP single port mode, which addresses the issue described in OpenCHAMI/deployment-recipes#86 (comment). With that configured, I can successfully retrieve resources over a LoadBalancer using the draft chart at OpenCHAMI/deployment-recipes#87 (comment)
Updates the
pin/tftp
dependency to v3. The new major was housekeeping for Go module stuff(see https://github.com/pin/tftp/releases/tag/v3.0.0), and is where all ongoing development will land upstream AFAICT. v3 is necessary for single port mode support.Refactor the plugin wrapper server construction to let us add new settings more cleanly and clean up several constants.
This results in a breaking change because of coredhcp plugin configuration requiring explicit values for all fields.