Skip to content

Allow microvm configuration from a single json passed as command line parameter #1212

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

Merged
merged 1 commit into from
Sep 17, 2019

Conversation

lauralt
Copy link

@lauralt lauralt commented Aug 12, 2019

Issue #923 , if available:

Description of changes:
Added extra parameter 'config-file' to Firecracker, which allows starting a microvm without sending API requests. User has to send in the start command a file which stores a single json, that contains the configuration for all of the resources used by the microvm. Also, added an integration test which successfully starts a microvm with a configuration file sent as command line parameter and unit tests.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@lauralt lauralt force-pushed the new_config branch 2 times, most recently from 388270a to 51aa257 Compare August 20, 2019 07:55
@alxiord alxiord self-requested a review August 21, 2019 07:42
@lauralt lauralt marked this pull request as ready for review August 26, 2019 08:57
Copy link
Contributor

@acatangiu acatangiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes LGTM for supporting the single json config from command line.

I'm a bit worried that we're missing a good opportunity to share the relevant parts with our API path so that we also support single API call config.
I believe clients that still need the API (e.g. for post-boot operations) would be highly grateful if they could do the single API call using their existing path (swagger-generated API client) instead of having to manually create JSONs and pass them as command-line args.

Copy link

@alxiord alxiord left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I forgot about the changelog again! This is a big change, so please update all the relevant docs:

  • add an entry in CHANGELOG.md
  • add an entry in FAQ.md
  • update jailer.md with the new parameter
  • add a section in getting-started.md#running-firecracker

I also totally forgot about the swagger spec and wouldn't have remembered if @acatangiu hadn't mentioned it. Customers can use it to autogenerate clients, so it should support the new payload format.

@alexandruag
Copy link
Contributor

I'm a bit worried that we're missing a good opportunity to share the relevant parts with our API path so that we also support single API call config.
I believe clients that still need the API (e.g. for post-boot operations) would be highly grateful if they could do the single API call using their existing path (swagger-generated API client) instead of having to manually create JSONs and pass them as command-line args.

That's a good point, but a bit outside the scope of this PR. The opportunity to build on top of this remains, and we can prioritize it if there's a real customer need, or pick it up as follow-up work at some point.

@acatangiu
Copy link
Contributor

I agree that we needn't target the single API call config in this PR, but I think that @lauralt has a good opportunity to do that as well (in subsequent PR/PRs) - it has real customer value.

@lauralt lauralt force-pushed the new_config branch 6 times, most recently from 2fc1712 to dd1c9ed Compare September 3, 2019 06:53
@lauralt lauralt requested review from acatangiu and alxiord September 3, 2019 07:49
acatangiu
acatangiu previously approved these changes Sep 10, 2019
acatangiu
acatangiu previously approved these changes Sep 10, 2019
@lauralt lauralt force-pushed the new_config branch 3 times, most recently from 914fe19 to 8795fb2 Compare September 11, 2019 08:13
acatangiu
acatangiu previously approved these changes Sep 11, 2019
@acatangiu acatangiu changed the title [RFC] Allow microvm configuration from a single json passed as command line parameter Allow microvm configuration from a single json passed as command line parameter Sep 16, 2019
@lauralt lauralt force-pushed the new_config branch 3 times, most recently from b2d29c3 to 270dcb8 Compare September 16, 2019 14:36
@lauralt lauralt force-pushed the new_config branch 2 times, most recently from 405664f to c2c3178 Compare September 17, 2019 07:32
acatangiu
acatangiu previously approved these changes Sep 17, 2019
acatangiu
acatangiu previously approved these changes Sep 17, 2019
@lauralt lauralt merged commit 58edf03 into firecracker-microvm:master Sep 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants