Commit Graph

258 Commits

Author SHA1 Message Date
Francesco Torchia 022cfe2c5a
Fix Ui crash in case of missing principal (#9762)
Signed-off-by: Francesco Torchia <francesco.torchia@suse.com>
2023-09-28 09:16:57 +01:00
Sean-McQ 6f0a3d436a
save method in model fixes payload, validator catches the rest (#9758) 2023-09-27 13:40:36 -04:00
Richard Cox a70fe1b431
Merge pull request #9598 from richard-cox/fix-modified-resource
Fix resource modified handler
2023-09-27 17:36:49 +01:00
Sean-McQ 70ad28eb3d
node to management node controller remaps status into internalNodeStatus (#9760)
Code that handles this on the backend: 9129a7b049/pkg/controllers/managementuser/nodesyncer/nodessyncer.go (L750)
2023-09-27 08:15:02 -04:00
richa 2ffe8d3170
App bar pin cluster (#9674)
* feat: app-bar init implementation

* fix: users e2e test

* chore: removes extra code

* fix: adds the correct width for the app-bar

* fix: addressing feedback

* fix: cleans up max-items preference, layout improvements

* chore: removes extra file

* feedback

* fixes issue with extra padding in standalone

* fix: loading overlay

* fix: spaces

* fix: missing content

* Added pin clusetr list

* Removed commented code

* Fixed sorted list order

* fix: fedback

* removes the 2px top

* fix: brings back the local cluster icon

* fix: adds cluster filter badge & cluster count

* Fix pin cluster test

* Rename pinned-clusters in pref

* Added pin methoded in cluster model

* Added test for unpinning cluster

* Fixed test

* Fixed lint

* Clean up css

* Resolved feedback

* Fixed lint

* Removed local cluster badge test

* Removed model

---------

Co-authored-by: scures <scurescu@suse.com>
2023-09-13 15:45:39 +02:00
Alexandre Alves 5c0da30362
New cluster template isn't displayed after repository refresh (#9612)
* force fetch and reset of catalog/load in order to get updated cluster templates every time we hit refresh on the cluster repo

* remove old solution + gate forceful catalog load to refresh action of clusterrepo

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MBP.lan>
2023-08-31 12:20:53 +01:00
Shavindra 51b47c2af1
Disable local cluster workspace change (#9552)
* Disable fleet workspace change for local cluster.
* Add LOCAL_CLUSTER constant.
2023-08-31 10:58:46 +02:00
Richard Cox f9aa1f38bb Fix resource modified handler
- fixes issue in handleConflict that meant
  - conflicts were not detected
  - non-conflicting changes were not applied to users resource
- see #9597 issue description for more detail
2023-08-25 18:41:04 +01:00
Shavindra e721ce3fe8
Handle correctdrift for previously created repos. (#9578)
* Handle correctdrift for previously created repos.
* Fix edit and Clone textbox
2023-08-25 12:18:19 +02:00
momesgin 17f5bb58aa
filter RKE1 s3 snapshots (#9460)
Co-authored-by: Mo Mesgin <mmesgin@Mos-M2-MacBook-Pro.local>
2023-08-02 09:03:24 -07:00
Richard Cox c906b55b42
Merge pull request #9440 from richard-cox/safer-chart-install
Add additional error handling to install chart page
2023-08-02 14:03:42 +01:00
Richard Cox dee580bad9 Changes following review with Neil
- try to find both from / to prov cluster
Also
- wrap creation of value in catch (just in case)
- only calc provClusterId once

Tested local cluster, imported cluster, rke1, rke2
2023-07-31 15:40:32 +01:00
Neil MacDougall 02e6e84f41
When execing into a container, try linux and windows commands when we can't determine if the node is windows (#9241)
* When execing into a container, try linux and windows commands when we can't determine if the node is windows

* Fix lint

* Lint: Remove trailing white space

* Use error message rather than last error

* extra failover, caching last working os against pod, errors, tests

* add __mocks__ folders to eslint ignore patterns

* standard user test fix

* removed unnecessary try/catch logic

* Revert "removed unnecessary try/catch logic"

This reverts commit c263131927.

---------

Co-authored-by: Sean <sean.mchugh@suse.com>
2023-07-28 21:28:03 -04:00
momesgin bac35d3a58
Merge pull request #9436 from momesgin/8839-disable-s3-snapshot
Disable failed S3 snapshots
2023-07-27 08:18:35 -07:00
Richard Cox 6f32ed0df2
Merge pull request #9412 from WuJun2016/circular-dependency
fix circular dependency
2023-07-27 11:39:53 +01:00
Mo Mesgin 8f19b3d53a check successful status instead of not failed 2023-07-26 16:18:35 -07:00
momesgin 7896059c49
filter failed snapshots (#9390)
* filter failed snapshots

* fixed import

* added one more test case

---------

Co-authored-by: Mo Mesgin <mmesgin@Mos-M2-MacBook-Pro.local>
2023-07-26 10:28:53 -07:00
Shavindra e11a73d6be
Fix fleet cluster labels and annotations save via YAML view. (#9383)
* Fix fleet cluster labels and annotations save via YAML view.
2023-07-26 13:25:31 +02:00
wujun f4856ffccc fix circular dependency 2023-07-26 17:45:27 +08:00
Shavindra eeb2a48330
Filter the bundles by label repo-name. (#9408) 2023-07-25 20:30:24 +02:00
Richard Cox 8558065b08 Fix how custom cluster drivers identify themselves
- the dashboard uses the kontainerdriver id for things like images, text and also to provide embedded ember with a key
- this works fine when the id is the type of kontainerdriver
- this doesn't if the kontainerdriver is custom and has a random id
  - for these cases use the status.displayName to use as an id instead
2023-07-21 16:49:55 +01:00
Giuseppe Leo 0208645b0f
(SURE-5538) Persistent Volume is not having CSI driver as vol plugin which is current default for latest versions of AKS (#9386)
* Move persistent volume constants and configurations away from model

* Add fallback for drivers with name only

* Enable support for CSI volume

* Prevent errors if no name is provided for route in CRUResource method

* Update test to check plugin options and value

* Update i18n
2023-07-20 23:31:50 +02:00
Shavindra f9a954a263
#4683 - Add fleet gitrepo resource age per cluster. (#9299)
* Add fleet gitrepo resource age per cluster.
2023-07-20 14:24:20 +02:00
Evgeniya Vashkevich c00445d501
Added UI to enable Fleet self-healing (#9310)
* Added UI to enable Fleet self-healing

* removed unused data-testid
2023-07-13 10:31:50 -07:00
Neil MacDougall c9e1a19396
Extension support for custom provisioning (#9246)
* Extension support for custom provisioning

* FIx lint issues

* Discovery / Tweaks
- fix issue where namespacesOverride was lost
- tidy up PROVIDER
- try to handle missing provider=type url param (could be missing extension-params)
- added a few comments to comments to come back to

* Names and typings
- change param --> customParam to make it clearer it's not url params
- add labels-annotations to shell types

* Wire in provider detailTabs
- as per original readme this should be made generic (extension point working directly with ResourceTabs)

* Update IClusterProvisioner & docs

* Improvements / Changes to support proving out DO extension
- cluster hooks optional
- buff up save hook (and pass in cluster when calling apply fn)
- move normalizeName into generic place
- bring back async create machine config
- hack for do extension (map example provider to do provider)

* updates, add optional saveCluster, add missing kube file
- saveCluster complements hooks, doesn't skip handling of addons, etc
- ensure register hooks take the `this` context in all worlds

* Adding docs

* Updates
- location config based changes
  - change customParams to context
  - add query param
- add new extention point to add tabs to cluster create cluster config section
- fixed some typing
- fixed issue where cluster was not passed to before / after hooks (only important if 'this' changes

* Changes following review, fix `t` in plugins

* Fix linting

* Docs updates, pass through more edit/view things

* Conditionally show the namespace grouping in the cluster list
- means users can differentiate between clusters with same name in different namespaces
- useful when clusters created via extension provisioner where ns can be selected

* docs tweaks, actually include the provisioning page in docs

---------

Co-authored-by: Richard Cox <richard.cox@suse.com>
2023-07-11 22:17:57 +01:00
Richard Cox dbb96deb12 Revert "Add additional permission check for cluster and project member admin (#9100)"
This reverts commit 1c6fc770d9.
2023-06-23 16:23:11 +01:00
Giuseppe Leo 01eeb0548f
Add recommended lint rules globally (#8997)
* Update configuration

* Create default config for eslint

* Restore plugin:vue/recommended

* Add exceptions and overrides

* Correct manually remaining issues

* Adding further picked exceptions groupped up

* Fix or disable specific cases manually and singularly

* Add naming linting exception

* Remove unused variable in component

* Move rules to default

* Autocorrect rancher/components linting issues

* Configure VSCode to use multiple files, to display linting for rancher components

* Disable jest lint hook restriction for string list component

* Autofix
2023-06-23 17:02:55 +02:00
Sean-McQ 1c6fc770d9
Add additional permission check for cluster and project member admin (#9100)
* Add additional permission check for cluster and project member admin

* Fixes the projectMembership editor on the edit project page

* per-project filtering for managing project-members on cluster/project

* Fixed admin behavior, simplified PRTB mgmt check,

* Optimise code
- Exit from cluster part early if
  - we're not ready to calc it
  - we've already calc'd it
- Move back calc of per project current user permissions to original loop
- Exit from project part early if
  - existing checks
  - we've already approved the

---------

Co-authored-by: Richard Cox <richard.cox@suse.com>
2023-06-19 13:07:18 -04:00
wujun 717a2b2c14
HARVESTER: add bare-metal container and mcm support (#8754)
* HARVESTER: add bare-metal container and mcm support

* Harvester: Fix re-render old route component

* HARVESTER: fix services and hide repositories

* HARVESTER: add svg icon

* HARVESTER: add harvester version in explorer page

* HARVESTER: change openRancherManagerSupport => isRancherInHarvester

* HARVESTER: move method to models type

* HARVESTER: enhancement TopLevelMenu when use embedded rancher

* HARVESTER: polish harvester mode judgment

* HARVESTER: Add namespace resource quota help text

* HARVESTER: remove service filter

* HARVESTER: set harvester-baremetal-container-workload to false

* HARVESTER: fix svg & namespace component

---------

Co-authored-by: n313893254 <n313893254@126.com>
2023-06-15 13:28:08 -07:00
Qingyang Nong 7c5ead687f
HARVESTER: Update LB design (#9087) 2023-06-13 10:55:17 -07:00
Giuseppe Leo 1e5057460f
Automation: Cronjob Run Now does generate resources in Jobs Detail page (#9026)
* Fix import issues

* Add cron job tests

* Add redirection test
2023-06-05 11:34:34 +02:00
Giuseppe Leo 312529d463
Updated memory value for node with reserved instead of capacity (#9014) 2023-06-01 17:32:43 +02:00
Richard Cox e10351733c Cluster and Project Members page fixes, Add back `Role` column to ClusterRoleBindings list
- Cluster tab
  - Remove prompt - Improved type name (Cluster Member --> Cluster Membership removes confusion with Cluster Member role)
- Projects tab
  - Fixed delete of membership to group. This would just delete the first binding that didn't have a user and was of the correct role
  - Remove prompt - Added name for projectroletemplatebinding type
  - Use same padding on right of Add button as on the left of the table
- CRB List
  - Removed custom header definition so native schema headers are used (with role)
2023-05-25 12:20:18 +01:00
Qingyang Nong c0cdc2dbf3
HARVESTER: Cloud provider enhancement (#8935)
* HARVESTER: Cloud provider enhancement

* fix labels-annotations.js linting

* fix missing comma in labels.vue

* fix labels.vue missing bracket

---------

Co-authored-by: Nancy Butler <42977925+mantis-toboggan-md@users.noreply.github.com>
2023-05-22 16:49:19 -07:00
Neil MacDougall 9fc18dd7c7
Fix incorrect i18n string for CSI suffix (#8936) 2023-05-22 12:32:22 +01:00
Neil MacDougall 25757ad1f2
Fix issue where project owner does not have permission to update PSP template bindings for a project (#8693) 2023-05-17 11:20:00 +01:00
Giuseppe Leo 43ce4e079c
Create unit test example of existing class models (#7726)
* Add list of cases to be covered for the model tests

* Create test cases for Namespace

* Pass empty object when creating new Namespace

* Add test about projectId in Namespace

* Remove mock for CI

* Remove unnecessary code
2023-05-15 18:57:36 +02:00
Richard Cox a359b728bc
Merge pull request #8833 from n313893254/remove-network
HARVESTER: Make NetworkAttachmentDefinitions generic in explorer
2023-05-15 17:37:06 +01:00
n313893254 78c24f47b9 HARVESTER: Make NetworkAttachmentDefinitions generic in explorer 2023-05-11 19:54:25 +08:00
LiuYan f1e16f5e12 fix missing job/pod resources on CronJobs/Jobs detail page 2023-05-11 15:42:56 +08:00
Neil MacDougall 68f3ffbcaa
Hostname truncation: Update to sync with backend (#8790)
* Update tio sync with backend

* Added getter

* Fix lint
2023-05-05 10:05:16 +01:00
Bastian Hofmann 3c955e6f52
Improve OPA Gatekeeper constraint detail page (#8586)
This adds the following functionality to the violations list on the OPA Gatekeeper constraint detail page:

* Add a namespace column to the violations
* Make the violations list searchable
* Allow to download the violations as a CSV, similar to CIS scanner violations

Signed-off-by: Bastian Hofmann <mail@bastianhofmann.de>
2023-04-27 09:27:37 +01:00
Richard Cox 0bba39e62c
Merge pull request #8158 from richard-cox/pods-in-workload-list
Include oprhaned `POD`s in Workload list
2023-04-21 13:59:38 +01:00
Shavindra 54e084f8fd
Fix clusterrolebindings (#8330)
* Fix ClusterRoleBindings listing.
* Update cluster members list view.
* Fix RBAC project users.
* Add role-binding icon.
2023-04-14 09:47:45 +01:00
Shavindra 6f8e6282ff
Disable Fleet workspace change for RKE2 clusters. (#8479)
* Disable Fleet workspace change for RKE2 clusters.
2023-03-27 08:37:13 +01:00
Alexandre Alves 9b23c52674
add check to resourceMethods prop so that UI doesnt fail when clusterTemplatesSchema is empty (#8414)
Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2023-03-14 09:01:28 +00:00
Alexandre Alves c44fa6088c
statefulsets pods list bug (#8268)
* change condition to check if buttons for scale up/scale down deployment are enabled

* revert changes

* fix error handling

* address PR comments

* fix incorrect pods list issue on statefulsets detail view

* address PR comments

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MBP.lan>
Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2023-03-10 15:32:03 +00:00
Neil MacDougall 2859ad0214
Fix OPA Gatekeeper constraint inconsistencies (#7979) 2023-03-09 21:24:36 +00:00
Neil MacDougall e231e09c5a
Fix mismatching tab name when ssh'ing into a node (#7914) 2023-03-08 22:08:16 +00:00
Richard Cox e3e72aef90 Fix edit of PSACT description
- Use `SteveDescriptionModel` as base of PodSecurityAdmissionTemplate model
- Provide a generic mechanism for model save to tweak the object that's saved
- In SteveDescriptionModel ensure the object that's saved has the correct description
  - Save worked for other users of class ... as they saved via norman rather than steve

Tweaks
- Removed duplicate PSACT definition
- Fixed width of PSACT table name / description columns
2023-03-08 13:29:57 +00:00