Skip to content
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

Lxc copy for clone lxc non exsiste in pylxd #514

Open
vincent-sensei opened this issue Aug 2, 2022 · 1 comment
Open

Lxc copy for clone lxc non exsiste in pylxd #514

vincent-sensei opened this issue Aug 2, 2022 · 1 comment

Comments

@vincent-sensei
Copy link

there is no function to clone the container with the native function of lxc copy?

@Mohamedemad4
Copy link

You can use the create function to clone containers by setting the source to container.

something like:

config  = {
    'name': ' name ',
    'source': {
        'type':'copy',
        'source': 'original-container' 
    }

lxd.create(config) # will clone original-container

see: https://pylxd.readthedocs.io/en/latest/instances.html#examples

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

No branches or pull requests

2 participants