-
-
Notifications
You must be signed in to change notification settings - Fork 309
File operations for custom storage volumes #2081
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
base: main
Are you sure you want to change the base?
Conversation
Looking into this one |
Did an initial cleanup pass, fixing the missing comments (reported by Code tests) and removed an |
Also re-generated the translations as that's needed when adding a new command. |
Also found some debug comments and added some missing line breaks. |
And also re-generated the API documentation. |
Signed-off-by: Stéphane Graber <[email protected]>
Closes lxc#1527 Signed-off-by: lahariguduru <[email protected]>
5900b21
to
75034c7
Compare
Okay, I've done enough cleanup that you can see the expected structure for this. Now for the actual review. This PR is extremely incomplete. The issue refers to implementing a file API similar to that for instances, this means:
At the API level, that means supporting:
As well as having a SFTP endpoint at: /1.0/storage-pools/POOL/volumes/custom/VOLUME/sftp The CLI should be based on what we have for instances (code should be shared, no need to duplicate it) and similar to instances, the CLI should just use SFTP, not the slower /files API, that's for scripting. All the API endpoints should behave identically to their And we obviously need some tests for this stuff too. |
Signed-off-by: lahariguduru <[email protected]>
Signed-off-by: lahariguduru <[email protected]>
Signed-off-by: Stéphane Graber <[email protected]>
Signed-off-by: Stéphane Graber <[email protected]>
75034c7
to
af9242c
Compare
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.
Looks like the right general areas of the code have been identified, but now this needs to be fully fleshed out with a real files API including SFTP support and client and CLI functions that match those already there for instances.
The net new code for this feature should be pretty minimal. All the needed client side and server side logic already exists for instances, the logic in question needs to be moved to common functions that can be called with the relevant path (either the container's rootfs or the custom storage volume's path).
Moved the issue back to draft. Please mark it as ready for review when the remaining bits have been implemented. |
I'm now looking into #2071 which will address part of this issue (there's overlap between the two). If we can get the /sftp endpoint and |
Finished Get and set up API Endpoint for issue #1527. This has been checked between client and daemon, and successfully executes the command.