2132 Commits

Author SHA1 Message Date
Abhisar Sinha
5c7e4b7edc
api: add ipaddress argument to disassociateIPAddress (#8222)
This PR adds argument 'ipadress' to the disassociateIpAddress api. IP address can be disassociated by directly giving the address instead of ID.

Fixes: #8125
2023-11-19 11:50:57 +05:30
Bryan Lima
1f29f6f040
Public IP quarantine feature (#7378) 2023-11-15 10:29:22 +01:00
Rohit Yadav
78213da828
appliance: use Debian 11.8.0 and systemvm version to 4.19.0 (#8084)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2023-11-02 16:50:03 +01:00
Vishesh
5362bad442
Storage Management (#7949) 2023-11-01 10:46:22 +01:00
Harikrishna
235e4fe190
Oauth2 integration with CloudStack (#7996)
OAuth2, the industry-standard authorization or authentication framework, simplifies the process of
granting access to resources. CloudStack supports OAuth2 authentication wherein users can login into
CloudStack without using a username and password. Support for Google and Github providers has been added.
Other OAuth2 providers can be easily integrated with CloudStack using its plugin framework.

The login page will show provider options when the OAuth2 is enabled and corresponding providers are configured.

"OAuth configuration" sub-section is present under "Configuration" where admins can register the corresponding
OAuth providers.
2023-10-31 13:25:28 +05:30
Wei Zhou
bd52fa8a12
New feature: VNF templates and appliances integration (#8022) 2023-10-27 10:23:00 +02:00
Vishesh
ea90848429
Feature: Add support for DRS in a Cluster (#7723)
This pull request (PR) implements a Distributed Resource Scheduler (DRS) for a CloudStack cluster. The primary objective of this feature is to enable automatic resource optimization and workload balancing within the cluster by live migrating the VMs as per configuration.
Administrators can also execute DRS manually for a cluster, using the UI or the API.
Adds support for two algorithms - condensed & balanced. Algorithms are pluggable allowing ACS Administrators to have customized control over scheduling.

Implementation
There are three top level components:

    Scheduler
    A timer task which:

    Generate DRS plan for clusters
    Process DRS plan
    Remove old DRS plan records

    DRS Execution
    We go through each VM in the cluster and use the specified algorithm to check if DRS is required and to calculate cost, benefit & improvement of migrating that VM to another host in the cluster. On the basis of cost, benefit & improvement, the best migration is selected for the current iteration and the VM is migrated. The maximum number of iterations (live migrations) possible on the cluster is defined by drs.iterations which is defined as a percentage (as a value between 0 and 1) of total number of workloads.

    Algorithm
    Every algorithms implements two methods:
        needsDrs - to check if drs is required for cluster
        getMetrics - to calculate cost, benefit & improvement of a migrating a VM to another host.

Algorithms

    Condensed - Packs all the VMs on minimum number of hosts in the cluster.
    Balanced - Distributes the VMs evenly across hosts in the cluster.
    Algorithms use drs.level to decide the amount of imbalance to allow in the cluster.

APIs Added

listClusterDrsPlan

    id - ID of the DRS plan to list
    clusterid - to list plans for a cluster id

generateClusterDrsPlan

    id - cluster id
    iterations - The maximum number of iterations in a DRS job defined as a percentage (as a value between 0 and 1) of total number of workloads. Defaults to value of cluster's drs.iterations setting.

executeClusterDrsPlan

    id - ID of the cluster for which DRS plan is to be executed.
    migrateto - This parameter specifies the mapping between a vm and a host to migrate that VM. Format of this parameter: migrateto[vm-index].vm=<uuid>&migrateto[vm-index].host=<uuid>.

Config Keys Added

    ClusterDrsPlanExpireInterval
    Key drs.plan.expire.interval
    Scope Global
    Default Value 30 days
    Description The interval in days after which old DRS records will be cleaned up.

    ClusterDrsEnabled
    Key drs.automatic.enable
    Scope Cluster
    Default Value false
    Description Enable/disable automatic DRS on a cluster.

    ClusterDrsInterval
    Key drs.automatic.interval
    Scope Cluster
    Default Value 60 minutes
    Description The interval in minutes after which a periodic background thread will schedule DRS for a cluster.

    ClusterDrsIterations
    Key drs.max.migrations
    Scope Cluster
    Default Value 50
    Description Maximum number of live migrations in a DRS execution.

    ClusterDrsAlgorithm
    Key drs.algorithm
    Scope Cluster
    Default Value condensed
    Description DRS algorithm to execute on the cluster. This PR implements two algorithms - balanced & condensed.

    ClusterDrsLevel
    Key drs.imbalance
    Scope Cluster
    Default Value 0.5
    Description Percentage (as a value between 0.0 and 1.0) of imbalance allowed in the cluster. 1.0 means no imbalance
    is allowed and 0.0 means imbalance is allowed.

    ClusterDrsMetric
    Key drs.imbalance.metric
    Scope Cluster
    Default Value memory
    Description The cluster imbalance metric to use when checking the drs.imbalance.threshold. Possible values are memory and cpu.
2023-10-26 11:48:18 +05:30
Abhishek Kumar
1bb6130795 Merge remote-tracking branch 'apache/4.18' into main 2023-10-20 11:00:22 +05:30
Abhishek Kumar
a2ec1f3777
marvin,test: fix directdownload template checksum test (#8096)
* marvin,test: fix directdownload template checksum test

During failure while deploying a VM with wrong checksum template, VM may be left in Error state. This PR adds code to delete such VM.

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>

* remove unnecessary logs

---------

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2023-10-19 19:40:03 +02:00
John Bampton
9834d5168f
pre-commit: standardize more line endings to lf (#7804)
https://github.com/pre-commit/pre-commit-hooks#mixed-line-ending
2023-10-18 11:25:00 +02:00
John Bampton
4eb110af73
Remove unneeded duplicate words (#7850) 2023-09-18 13:16:33 +02:00
Wei Zhou
246bb24b0f Updating pom.xml version numbers for release 4.18.2.0-SNAPSHOT
Signed-off-by: Wei Zhou <weizhou@apache.org>
2023-09-12 17:26:53 +02:00
Wei Zhou
4bdff06acd Updating pom.xml version numbers for release 4.18.1.0
Signed-off-by: Wei Zhou <weizhou@apache.org>
2023-09-07 08:50:50 +02:00
Daan Hoogland
ea832bce13 Merge branch '4.18' 2023-08-22 11:44:45 +02:00
Marcus Sorensen
6cded7e010
Support GNU sed apidoc for MacOS build (#7888)
Co-authored-by: Marcus Sorensen <mls@apple.com>
2023-08-22 14:31:20 +05:30
Wei Zhou
540dcc1040 Merge remote-tracking branch 'apache/4.18' 2023-08-11 08:30:07 +02:00
Rohit Yadav
29c7b3167e
cloudstack: bump to use 4.18.1.0 systemvmtemplate (#7828)
* cloudstack: bump to use 4.18.1.0 systemvmtemplate

Use new 4.18.1.0 systemvmtemplate

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

* fix cd ISO url

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

---------

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2023-08-11 07:38:47 +02:00
Daan Hoogland
7b64236469 Merge release branch 4.18 to main
* 4.18:
  server: remove registered userdata when cleanup an account (#7777)
  server: Use max secondary storage defined on the account during upload  (#7441)
  test: upgrade kubernetes versions to 1.25.0/1.26.0 (#7685)
  kvm: Added VNI Devices as normal bridge slave devs (#7836)
  noVNC: fix JP keyboard on vmware7+ which uses websocket URL (#7694)
2023-08-10 14:50:46 +02:00
Wei Zhou
b32ba953cf
test: upgrade kubernetes versions to 1.25.0/1.26.0 (#7685)
* test: upgrade versions to 1.25.0/1.26.0

* PR7685: move settings to test_data.py
2023-08-10 09:48:08 +02:00
John Bampton
6f4503488b
pre-commit: apply end-of-file-fixer to all files (#7551) 2023-08-02 13:47:21 +02:00
Vishesh
594c70dde0
Sync precommit config from main (#7732)
Co-authored-by: John Bampton <jbampton@users.noreply.github.com>
Co-authored-by: dahn <daan@onecht.net>
2023-07-07 11:18:16 +02:00
Rohit Yadav
5975ea80c9 Merge remote-tracking branch 'origin/4.18' 2023-06-27 15:51:40 +05:30
Wei Zhou
f3ad9e6743
marvin: fix smoke test failures if mgmt server is Ubuntu (#7583) 2023-06-27 11:57:02 +02:00
dahn
06caf32bc8
Guest os mappings improvements (#6979)
* Guest OS mapping improvements
- Checks the OS mapping name in hypervisor (VMware, XenServer)
- Displays guest OS mappings in UI

* Added API getHypervisorGuestOsNames to list the guest OS names in the hypervisor, and code improvements

* Some static analysis fixes

* Removed commented code in listview

* Guest OS list

* UI changes for adding guest os and mappings

* Added guest os mappings in guest os form

* Added new filter to guest os mapping

* Name and description changes

* VMWare Host and cluster MO unit tests

* CheckGuestOsMapping command and answer unit tests

* GetHypervisorGuestOsNames command and answer unit tests

* VmwareResource unitests

* GuestOsMapper unittests

* icon changes

* Addressed review comments

* Renaming fixes

* Removed comments

* marvin tests for guest os operations

* Added marvin tests for OS mappings

* Document links and UI improvements

* Added deduplication for the list guest OS API

* Fixed linter failure

* Few bug fixes and UI changes

* Few improvements

* Addressed code smells

* Fixed UI issues after rebase

---------

Co-authored-by: Suresh Kumar Anaparti <sureshkumar.anaparti@gmail.com>
Co-authored-by: Harikrishna Patnala <harikrishna.patnala@gmail.com>
2023-06-27 13:49:20 +05:30
Vishesh
fa3f2a75eb
feature: VM Scheduler (#7397)
This PR adds a feature to setup schedules to stop/start/restart your VMs.

Documentation PR: apache/cloudstack-documentation#313
Related issue: #3387
2023-06-26 13:36:46 +05:30
dahn
ae10263b3b
Possibility to choose the source NAT IP address on a isolated network or VPC (#6442)
Co-authored-by: NuxRo <nux@li.nux.ro>
Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>
2023-06-09 14:51:53 +02:00
Abhishek Kumar
c00a1ba532 Merge remote-tracking branch 'apache/4.18' into main 2023-06-08 15:34:46 +05:30
Abhishek Kumar
03910c2783 Merge remote-tracking branch 'apache/4.17' into 4.18 2023-06-08 15:34:03 +05:30
Abhishek Kumar
20865901d1 Merge remote-tracking branch 'apache/4.16' into 4.17 2023-06-08 15:33:20 +05:30
Abhishek Kumar
24da2bcf78
marvin: fix test_data for parsing failure (#7602)
PR #6512 seems to have broken the test_data.py. This PR fixes test_data.
2023-06-08 15:32:04 +05:30
Abhishek Kumar
6ea5f56e62 Merge remote-tracking branch 'apache/4.18' into main 2023-06-06 13:12:55 +05:30
Abhishek Kumar
b030ea19a4 Merge remote-tracking branch 'apache/4.17' into 4.18 2023-06-06 13:12:12 +05:30
Abhishek Kumar
f298008215 Merge remote-tracking branch 'apache/4.16' into 4.17 2023-06-06 13:11:24 +05:30
Pearl Dsilva
bd5d478a3a
Refactor test and change IP range (#6512)
* Refactor test and change IP range

* countdown from 254 to allow multiple pseudo public nets counting up from 0

* cleanup

* location of asserts improved

---------

Co-authored-by: dahn <daan.hoogland@gmail.com>
Co-authored-by: Daan Hoogland <daan@onecht.net>
2023-06-05 16:39:33 +02:00
Rohit Yadav
ce44ff4148 Merge remote-tracking branch 'origin/4.18' 2023-05-25 22:16:16 +05:30
Rohit Yadav
4138ca7c5d systemvmtemplate: fix Debian 11.7.0 ISO URL
Fixes systemvmtemplate build issue

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2023-05-25 22:15:28 +05:30
nvazquez
0024cb0372
Merge branch '4.18' 2023-05-24 11:01:10 -03:00
Vishesh
83fd75f707
Marvin: Fix deployDataCenter's cleanup (#7521) 2023-05-12 10:46:52 +02:00
Wei Zhou
ea2b537985
fix tools/build/setnextversion.sh: do not update tools/apidoc/pom.xml (#7163)
Steps to reproduce the issue

(1) on ubuntu server, run "git checkout 4.17.2.0"
(2) packaging
cd packaging/
./build-deb.sh -b test1

expected result: succeed
actual result:

[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR]   The project org.apache.cloudstack:cloud-apidoc:4.17.2.0-test1-test1 (/data/cloudstack/tools/apidoc/pom.xml) has 1 error
[ERROR]     Non-resolvable parent POM for org.apache.cloudstack:cloud-apidoc:4.17.2.0-test1-test1: Could not find artifact org.apache.cloudstack:cloud-tools:pom:4.17.2.0-test1-test1 in central (https://repo.maven.apache.org/maven2) and 'parent.relativePath' points at wrong local POM @ line 25, column 13 -> [Help 2]
2023-05-08 13:00:36 +02:00
Rohit Yadav
a2561df25b Merge remote-tracking branch 'origin/4.18' 2023-05-08 12:57:38 +05:30
dahn
897dad619b
marvin: replace encodestring for encodebytes (#7027)
Fixes: #6962
2023-05-08 12:51:12 +05:30
GaOrtiga
8b5bfb145e
create parameter to determine whether roles are public or private (#6960)
Co-authored-by: Gabriel Ortiga Fernandes <gabriel.fernandes@scclouds.com.br>
Co-authored-by: dahn <daan.hoogland@gmail.com>
2023-05-01 15:26:10 +02:00
kishankavala
69be0af32d
Allow admin/users to add comments to Management Servers (#7379)
* UI changes for management server comments

* Added support for mgmt server comments in annotations framework

* Added test for mgmt server annotation

* changed annotation to be unique for mgmt server test
2023-04-18 14:16:55 +05:30
David Jumani
941cc83372
Feature: Safely shutdown cloudstack (#6755)
Co-authored-by: dahn <daan.hoogland@gmail.com>
2023-04-12 12:44:14 +02:00
John Bampton
c2e17310d6
Add three more pre-commit checks (#7083)
Co-authored-by: dahn <daan@onecht.net>
2023-03-27 13:28:55 +02:00
Rohit Yadav
1d2e3fe24d Merge remote-tracking branch 'origin/4.18'
Fix 4.19/main build and add upgrade path from 4.18.1.0->4.19.0.0

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2023-03-16 13:36:04 +05:30
Rohit Yadav
74a414e76f Fix build failure and 4.18.0.0->4.18.1.0 upgrade path
Unblocks smoketests/health check runs on 4.18 branch.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2023-03-16 13:18:26 +05:30
Daan Hoogland
fb4f6a334d Updating pom.xml version numbers for release 4.19.0.0-SNAPSHOT
Signed-off-by: Daan Hoogland <daan@onecht.net>
2023-03-15 19:46:01 +01:00
Daan Hoogland
05cda2729f Updating pom.xml version numbers for release 4.18.1.0-SNAPSHOT
Signed-off-by: Daan Hoogland <daan@onecht.net>
2023-03-15 19:38:14 +01:00
Daan Hoogland
0574087284 Updating pom.xml version numbers for release 4.18.0.0
Signed-off-by: Daan Hoogland <daan@onecht.net>
2023-03-11 09:35:41 +01:00