35302 Commits

Author SHA1 Message Date
Rohit Yadav
35b5315dae
maven: update dependencies (#6539)
This upgrades mvn dependencies for the project.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2022-07-11 20:41:39 +05:30
Rohit Yadav
e1c7a447cc Merge remote-tracking branch 'origin/4.17' 2022-07-09 22:01:55 +05:30
Harikrishna
65b0bcb069
api: Deprecated changeServiceForVirtualMachine API and replaced all the occurences in the tests with scaleVirtualMachine (#6540) 2022-07-09 21:52:51 +05:30
Harikrishna
ab9a0fd69f
Updated log message and throw error when unable to update the secret key file (#6542)
This PR fixes issue #6232 to update the error message and throw the error when updating key file is failed. This helps to find out the proper reason for failure, mainly with umask.
2022-07-09 21:21:11 +05:30
Abhishek Kumar
764ee30ecc
ui: fix zone icon in vm deploy zone selection (#6543)
* ui: fix zone icon in vm deploy zone selection

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

* unnecessary conditions

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2022-07-08 20:00:04 +05:30
Hoang Nguyen
600d81e345
UI: Fixes some issues from zone wizard with VMWare hypervisor (#6480)
* hide html warning in message

* hidden ip address step

* refill value of edit tariff

* close modal when icon-close clicked

* fixes modal not show when error

* check valid traffic label with VMWare

* remove automatic change clustername
2022-07-08 13:53:12 +05:30
Rohit Yadav
0cae4406fb Merge remote-tracking branch 'origin/4.17' 2022-07-07 14:37:34 +05:30
Rohit Yadav
d8da5e650d
kvm: add support nicAdapter detail for vm and template settings for KVM (#6536)
Fixes #6533

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2022-07-07 14:36:36 +05:30
Rohit Yadav
3d316546bf
kvm: skip test that can't run and pass on M1 mac (#6537)
This fixes the build issue on M1 mac/osx.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2022-07-07 14:36:15 +05:30
John Bampton
a039250b3b
.github: Lint modified files only with Super-Linter (#6531)
https://github.com/github/super-linter#standard-image
2022-07-07 11:57:29 +05:30
Rohit Yadav
7ff3e7f968 Merge remote-tracking branch 'origin/4.17'
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2022-07-06 12:53:45 +05:30
Abhishek Kumar
67e941f690
cks: fix k8s version upgrade (#6513)
Fixes #6514

On latest systemvm template used for CKS /usr/sbin is not present in the $PATH for normal user used during upgrade. This leads to failure for blkid command. Due to this during k8s version upgrade ISO is not being able to mount on the k8s cluster VMs and upgrade process is not carried out.
This PR fixes mounting of k8s version ISO and also returns failure for script when ISO mounting is failed.
Same failure is not seen during deployment of the cluster because setup-kube-system workflow is executed as ROOT user and it has a different value for $PATH.
From /etc/login.defs:

ENV_SUPATH	PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
ENV_PATH	PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2022-07-06 12:34:49 +05:30
Hoang Nguyen
9e5cda59ce
UI: Add authmethod field allowing to choose password or ssh key when adding host (#6525)
* add authmethod to addhost in zone wizard

* add a condition for hiding password field

* set default value when switch hypervisor

* add more value for authmethod
2022-07-06 12:16:09 +05:30
Rohit Yadav
e57a0f9980 Merge remote-tracking branch 'origin/4.17' 2022-07-06 09:34:02 +05:30
Luis Moreira
c6b611433b
saml: Fix SAML SSO plugin redirect URL (#6457)
This PR fixes the issue #6427 -> SAML request must be appended to an IdP URL as a query param with an ampersand, if the URL already contains a question mark, as opposed to always assume that IdP URLs don't have any query params.
Google's IdP URL for instance looks like this: https://accounts.google.com/o/saml2/idp?idpid=<ID>, therefore the expected redirect URL would be https://accounts.google.com/o/saml2/idp?idpid=<ID>&SAMLRequest=<SAMLRequest>

This code change is backwards compatible with the current behaviour.
2022-07-06 09:28:37 +05:30
Abhishek Kumar
f1bce69b5d
ui: allow instances to be filtered by group (#6495)
Fixes #6428

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2022-07-06 09:26:31 +05:30
Harikrishna
2c49d714b5
scripts: Excluded fe80 or link local address in keystore setup (#6530)
This PR fixes the issue #6471 where in keystore setup does not exclude link-local addresses.

We have fixed the keystore setup process to exclude the fe80 or link local addresses
2022-07-06 09:20:13 +05:30
Abhishek Kumar
6ec06aecd7
refactor: new line, lint error fix (#6529)
Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
2022-07-05 20:27:40 +05:30
mprokopchuk
aa7dd309db
Create event TEMPLATE_UPDATE for virtual machine image update calls. (#6521)
* Create event TEMPLATE_UPDATE for virtual machine image update calls.

(cherry picked from commit e7eec8d0daf5c3d0d5d7c636504f963094788311)

* Added ISO.UPDATE event for update ISO command.

(cherry picked from commit 277f76f398e089af1795d0a3e75749d9a475cae0)

Co-authored-by: Maxim Prokopchuk <mprokopchuk@apple.com>
2022-07-05 10:41:02 +02:00
Daan Hoogland
a470f3353a Merge branch '4.17' 2022-07-05 09:11:45 +02:00
John Bampton
7d23a0a759
Fix spelling (#6272) 2022-07-05 09:08:53 +02:00
Hoang Nguyen
8a229baac5
clear all filter values after the reset button clicked (#6503) 2022-07-01 23:38:52 -03:00
João Jandre
e467ad02ce
Fix VMware memory retrieval (#6414)
* Fix VMware memory retrieval

* Address review

Co-authored-by: Joao <JoaoJandre@gitlab.com>
2022-07-01 23:36:40 -03:00
Rohit Yadav
711d4b9f0f Merge remote-tracking branch 'origin/4.17' 2022-07-01 11:26:10 +05:30
Rohit Yadav
85df82c2a9 Revert ".github: try using just sonarcloud job on pull_request target only"
This reverts commit aad73322aff1a5b1393c024949c6ba0b021a4c90.
2022-07-01 11:25:27 +05:30
neilnaveen
15ab481928
chore: Set permissions for GitHub actions (#6467)
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)

Signed-off-by: neilnaveen <42328488+neilnaveen@users.noreply.github.com>
2022-07-01 11:24:04 +05:30
Daniel Augusto Veronezi Salvador
7d932e574d
engine/schema: Fix API deleteTrafficType not filtering physical network (#6510)
While deleting a traffic type, ACS validates if there is any VM related to it. However, if we have several physical networks containing a traffic type, ACS does not filter the physical network to do the validation. For instance, if we have two (2) physical networks containing the traffic type Guest, the first one having VMs related, and the second not having VMs related, if we try to remove the second traffic type, ACS give us the message The Traffic Type is not deletable because there are existing networks with this traffic type:Guest.

The API deleteTrafficType was designed to filter the physical network where the traffic type is, however, due to a typo this filtering was not been applied correctly. This PR intends to fix this typo to honor the API behavior.

In an advanced zone I created 4 physical networks, one for each traffic type (Public, Guest, Management, Storage). I instantiated some VMs so they get guest IPs. In the Public physical network I added a Guest traffic type. I tried to remove the new Guest traffic type from Public physical network, which did not have any VMs related to it, and, before the changes, I was getting the message The Traffic Type is not deletable because there are existing networks with this traffic type:Guest. After the changes, I could remove successfully the new Guest traffic type via API deleteTrafficType. I also tried to remove the Guest traffic type which had VMs related to it, however, as expected, I received the The Traffic Type is not deletable... message.

I also created a unit test to validate the data retrieving.

Co-authored-by: GutoVeronezi <daniel@scclouds.com.br>
2022-07-01 11:21:41 +05:30
Rohit Yadav
6607a98597 Merge remote-tracking branch 'origin/4.17' 2022-07-01 10:44:29 +05:30
Harikrishna
637a102922
Fix for VMware VM migration with volume in local storage (#6483)
* Fix VMware VM migration with volume in case of local storage

* Break the loop once target host is found

* Code optimisations in getting the target host guid for local storage

* Fixed code smells and added unit test
2022-07-01 10:39:02 +05:30
Harikrishna
2326164c17
api: Added information about deviceid 0 to attach root volume to VM (#6518)
This is in the workflow of attaching and detaching a root volume of a VM. We can detach the root volume from a VM and Cloudstack marks it as datadisk. We can reattach the volume to make it root volume again. During attach Device ID 0 has to be passed so that the volume will be converted back to ROOT again

Added a small information in the DeviceID section in Attach volume form.
2022-06-30 17:36:42 +05:30
Rohit Yadav
5fe095ee0a Merge remote-tracking branch 'origin/4.17' 2022-06-30 15:28:55 +05:30
Rohit Yadav
aad73322af .github: try using just sonarcloud job on pull_request target only
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2022-06-30 15:27:20 +05:30
Rohit Yadav
3fc825e246 Merge remote-tracking branch 'origin/4.17' 2022-06-30 12:17:29 +05:30
Rohit Yadav
20420c4907 Merge remote-tracking branch 'origin/4.16' into 4.17 2022-06-30 12:16:05 +05:30
Hoang Nguyen
3753772ece
UI: Remove unused dependencies and fix travis build (#6142)
* remove unused dependencies and fix travis build

* fixes

* revert node-sass

* update package-lock.json
2022-06-30 12:12:26 +05:30
John Bampton
7ba43e447c
Enable flake8 rule W292 No newline at end of file (#6274)
https://www.flake8rules.com/rules/W292.html
2022-06-30 12:08:27 +05:30
Wei Zhou
a9a2aa953c
CKS: add created to k8s cluster and k8s version (#6446)
This PR adds created info to the response of kubernetes clusters and kubernetes supported version.
2022-06-30 12:03:12 +05:30
Wei Zhou
ae46c33b65
server: update lb rule with new protocol (#6476)
* server: update lb rule with new protocol

* Update PR #4746: use StringUtils.isNotBlank() instead
2022-06-30 12:02:09 +05:30
Harikrishna
089e9647f1
Fix global setting reference for max secondary storage (#6496)
* Fix global setting reference for max secondary storage usage based on account or project

* Changed a variable naming

* Replaced config enum usage with configkey class for global settings

* Fixed grammar mistake

* Fixed code smells
2022-06-30 11:42:58 +05:30
Bryan Lima
c1cb84b493
Updating and adding missing labels on pt_BR locale (#6154)
* Updating and adding missing labels on pt_BR locale

* Apply suggestions from code review

Co-authored-by: SadiJr <sadijacinto@gmail.com>

* Addressing Sadi reviews

* Apply suggestions from code review

Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>

* Addressing reviews and standardizing entities to lowercase

* Apply suggestions from code review

Co-authored-by: SadiJr <sadijacinto@gmail.com>

* Addressing Sadi reviews

* Address reviews

* Apply suggestions from code review

Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>

* Address Daniel reviews

* Address Daniel reviews

Co-authored-by: SadiJr <sadijacinto@gmail.com>
Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>
2022-06-28 09:41:35 -03:00
SadiJr
ea9124e49c
[KVM improve logs in migrate VM process (#6331)
* Add more logs to migrate VM process in KVM

* Remove unused imports

* Verify if debug is enable before write the log string

* Fix conflicts

Co-authored-by: Daniel Augusto Veronezi Salvador <daniel@scclouds.com.br>
Co-authored-by: SadiJr <sadi@scclouds.com.br>
2022-06-28 08:58:19 +02:00
Marcus Sorensen
7b0ebe2e37
Allow for arbitrary disk offering details to be saved/displayed (#6474)
* Allow for arbitrary disk offering details to be saved/displayed

Similar to service offering details, allow details to be provided and
displayed. Can be used for classification of offerings, etc.

Signed-off-by: Marcus Sorensen <mls@apple.com>

* Update server/src/main/java/com/cloud/configuration/ConfigurationManagerImpl.java

Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>

Co-authored-by: Daniel Augusto Veronezi Salvador <38945620+GutoVeronezi@users.noreply.github.com>
2022-06-28 08:57:18 +02:00
Wei Zhou
ff7831d751 Merge remote-tracking branch 'apache/4.17' 2022-06-28 08:27:36 +02:00
hooklee2000
aee7bb9e34
UI fix message.add.vpn.customer.gateway.failed when catched error (#6493)
* UI fix message.add.vpn.customer.gateway.failed when catched error

* fix UI VPC add ACL  without required input  close ui 

Without any input, click ok button then close the ui . We need display ui to confirm all required input.

* remove commented line
2022-06-28 10:53:25 +05:30
Hoang Nguyen
739be5d002
UI: Change notification title when resizing volume (#6502)
* fixes resize volume message

* Update ui/public/locales/en.json

Co-authored-by: Suresh Kumar Anaparti <sureshkumar.anaparti@gmail.com>

* Update ui/src/views/storage/ResizeVolume.vue

Co-authored-by: Suresh Kumar Anaparti <sureshkumar.anaparti@gmail.com>

Co-authored-by: Suresh Kumar Anaparti <sureshkumar.anaparti@gmail.com>
2022-06-28 10:50:48 +05:30
Wei Zhou
dd3bd21fab
UI: fix create tags for LB rules (#6475) 2022-06-27 14:24:55 +02:00
Bryan Lima
e1fb2be835
Add check for update only name and/or description of disk offering (#6410)
* Add check for update only name and/or description of disk offering

* Add check to update only name and/or description of service offerings as well
2022-06-27 13:24:37 +02:00
Suresh Kumar Anaparti
c70bc9d69c
kvm: Updated PowerFlex/ScaleIO storage plugin to support separate (storage) network for Hosts(KVM)/Storage connection. (#6367)
This PR enhances the existing PowerFlex/ScaleIO storage plugin to support separate (storage) network for Hosts(KVM)/Storage connection, mainly the SDC (ScaleIo Data Client) connection.
2022-06-27 14:42:51 +05:30
João Jandre
8448fe27a6
Enable CPU cap for SSVMs and CPVMs (#6420)
* Enable CPU cap for SSVMs and CPVMs

* Resolve conflicts

Co-authored-by: Joao <JoaoJandre@gitlab.com>
2022-06-24 16:56:29 -03:00
João Jandre
6ac14fad1b
Removed unused labels (#6326)
* Removed unused labels.

* Readd some labels that were being used

Co-authored-by: Joao <JoaoJandre@gitlab.com>
2022-06-23 15:31:52 +02:00