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

instant clone feature #60004

Merged
merged 13 commits into from
Jan 21, 2022
Merged

instant clone feature #60004

merged 13 commits into from
Jan 21, 2022

Conversation

Anant99-sys
Copy link

@Anant99-sys Anant99-sys commented Apr 11, 2021

What does this PR do?

Implementation for instant clone functionality

The Instant Clone technology is used to create powered-on virtual machines from the running state of another powered-on virtual machine.
The result of an Instant Clone operation is a new virtual machine that is identical to the source virtual machine.
With Instant Clone you can create new virtual machines from a controlled point in time.
Instant cloning is very convenient for large-scale application deployments because it ensures memory efficiency and allows for creating numerous virtual machines on a single host.
This functionality can be used for Creating a powered-on Instant Clone of a virtual machine.

Merge requirements satisfied?

[NOTICE] Bug fixes or features added to Salt require tests.

Commits signed with GPG?

No

Please review Salt's Contributing Guide for best practices.

See GitHub's page on GPG signing for more information about signing commits with GPG.

@Anant99-sys Anant99-sys requested a review from a team as a code owner April 11, 2021 12:03
@Anant99-sys Anant99-sys requested review from twangboy and removed request for a team April 11, 2021 12:03
@welcome
Copy link

welcome bot commented Apr 11, 2021

Hi there! Welcome to the Salt Community! Thank you for making your first contribution. We have a lengthy process for issues and PRs. Someone from the Core Team will follow up as soon as possible. In the meantime, here’s some information that may help as you continue your Salt journey.
Please be sure to review our Code of Conduct. Also, check out some of our community resources including:

There are lots of ways to get involved in our community. Every month, there are around a dozen opportunities to meet with other contributors and the Salt Core team and collaborate in real time. The best way to keep track is by subscribing to the Salt Community Events Calendar.
If you have additional questions, email us at core@saltstack.com. We’re glad you’ve joined our community and look forward to doing awesome things with you!

@Anant99-sys
Copy link
Author

Hey @twangboy can you please review this feature and suggest all the required changes necessary for the feature to be merged?

twangboy
twangboy previously approved these changes Apr 19, 2021
@twangboy twangboy added the Silicon v3004.0 Release code name label Apr 19, 2021
@twangboy twangboy added this to the Silicon milestone Apr 19, 2021
Copy link
Contributor

@Ch3LL Ch3LL left a comment

Choose a reason for hiding this comment

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

This will also require a changelog file and documentation for the new feature.

salt/cloud/clouds/vmware.py Show resolved Hide resolved
@Anant99-sys Anant99-sys requested review from twangboy and Ch3LL May 10, 2021 11:51
Ch3LL
Ch3LL previously approved these changes May 17, 2021
@sagetherage sagetherage removed the Silicon v3004.0 Release code name label Aug 25, 2021
@sagetherage sagetherage removed this from the Silicon milestone Aug 25, 2021
@Anant99-sys
Copy link
Author

@Ch3LL what's the status of this feature?

@Ch3LL Ch3LL added the Phosphorus v3005.0 Release code name and version label Dec 8, 2021
@Ch3LL
Copy link
Contributor

Ch3LL commented Jan 14, 2022

I was able to get the tests passing here: #60383

Can you make these changes and we can get this merged in:

diff --git a/tests/integration/cloud/clouds/test_vmware.py b/tests/integration/cloud/clouds/test_vmware.py
index bd95f7ca4a..9dd396ff03 100644
--- a/tests/integration/cloud/clouds/test_vmware.py
+++ b/tests/integration/cloud/clouds/test_vmware.py
@@ -99,9 +99,9 @@ class VMWareTest(CloudTest):
         Tests creating Instant Clone VM
         """
         # salt-cloud -p my-instant-clone IC3
-        profile_name = "my-instant-clone"
+        profile_name = "vmware-test-instant-clone"
         self.add_profile_config(
-            "vmware-test", {"verify_ssl": False}, "vmware.conf", profile_name
+            "vmware-test", {"instant_clone": True}, "vmware.conf", profile_name
         )
         # create the instance
         ret_val = self.run_cloud(
diff --git a/tests/integration/files/conf/cloud.profiles.d/vmware.conf b/tests/integration/files/conf/cloud.profiles.d/vmware.conf
index 1d16cddca1..2e5d54f4b5 100644
--- a/tests/integration/files/conf/cloud.profiles.d/vmware.conf
+++ b/tests/integration/files/conf/cloud.profiles.d/vmware.conf
@@ -1,7 +1,6 @@
 vmware-test:
   provider: vmware-config
   clonefrom: ''
-  instant_clone: ''
   num_cpus: 1
   memory: 2GB
   devices:

@Anant99-sys
Copy link
Author

I was able to get the tests passing here: #60383

Can you make these changes and we can get this merged in:

diff --git a/tests/integration/cloud/clouds/test_vmware.py b/tests/integration/cloud/clouds/test_vmware.py
index bd95f7ca4a..9dd396ff03 100644
--- a/tests/integration/cloud/clouds/test_vmware.py
+++ b/tests/integration/cloud/clouds/test_vmware.py
@@ -99,9 +99,9 @@ class VMWareTest(CloudTest):
         Tests creating Instant Clone VM
         """
         # salt-cloud -p my-instant-clone IC3
-        profile_name = "my-instant-clone"
+        profile_name = "vmware-test-instant-clone"
         self.add_profile_config(
-            "vmware-test", {"verify_ssl": False}, "vmware.conf", profile_name
+            "vmware-test", {"instant_clone": True}, "vmware.conf", profile_name
         )
         # create the instance
         ret_val = self.run_cloud(
diff --git a/tests/integration/files/conf/cloud.profiles.d/vmware.conf b/tests/integration/files/conf/cloud.profiles.d/vmware.conf
index 1d16cddca1..2e5d54f4b5 100644
--- a/tests/integration/files/conf/cloud.profiles.d/vmware.conf
+++ b/tests/integration/files/conf/cloud.profiles.d/vmware.conf
@@ -1,7 +1,6 @@
 vmware-test:
   provider: vmware-config
   clonefrom: ''
-  instant_clone: ''
   num_cpus: 1
   memory: 2GB
   devices:

Sorry I saw your reply now only. I see you have added the above-requested changes. Is anything else required?

@Ch3LL
Copy link
Contributor

Ch3LL commented Jan 20, 2022

There is a pre-commit failure, but I can fix that real quick right now. I have asked the team to review the PR since I helped with the commits on this PR. Once there are reviews and passing tests we can get this one merged in. Thanks

@Ch3LL Ch3LL merged commit eed47a5 into saltstack:master Jan 21, 2022
@welcome
Copy link

welcome bot commented Jan 21, 2022

Congratulations on your first PR being merged! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Phosphorus v3005.0 Release code name and version
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants