chore: Updates to gcp hc form (#2649)
* chore: 🤖 add worker_filter field, updates to helper text
This commit is contained in:
1 parent
cc8d4fe952
commit
3b6a421af2
9 files changed
+69
-25
No files matched your search
@@ -67,18 +67,20 @@ export default class GeneratedHostCatalogModel extends BaseModel {
|
||||
})
|
||||
disable_credential_rotation;
|
||||
|
||||
// AWS specific
|
||||
// AWS and GCP specific
|
||||
|
||||
@attr('string', {
|
||||
for: {
|
||||
type: 'plugin',
|
||||
name: 'aws',
|
||||
name: ['aws', 'gcp'],
|
||||
},
|
||||
description:
|
||||
'An expression used to filter the workers that have network access to a service that is hosting the external object store.',
|
||||
})
|
||||
worker_filter;
|
||||
|
||||
// AWS specific
|
||||
|
||||
@attr('string', {
|
||||
for: {
|
||||
type: 'plugin',
|
||||
|
||||
@@ -53,7 +53,8 @@ export default factory.extend({
|
||||
worker_filter: function () {
|
||||
if (
|
||||
this.type === TYPE_HOST_CATALOG_DYNAMIC &&
|
||||
this.plugin?.name === TYPE_HOST_CATALOG_PLUGIN_AWS
|
||||
(this.plugin?.name === TYPE_HOST_CATALOG_PLUGIN_AWS ||
|
||||
this.plugin?.name === TYPE_HOST_CATALOG_PLUGIN_GCP)
|
||||
) {
|
||||
return `"${faker.word.noun()}" in "${faker.system.directoryPath()}"`;
|
||||
}
|
||||
|
||||
@@ -217,6 +217,7 @@ module('Unit | Serializer | application', function (hooks) {
|
||||
name: 'GCP plugin',
|
||||
description: 'this is a GCP plugin host-catalog',
|
||||
type: 'plugin',
|
||||
worker_filter: 'workerfilter',
|
||||
attributes: {
|
||||
disable_credential_rotation: true,
|
||||
project_id: 'project',
|
||||
|
||||
@@ -68,6 +68,7 @@ module('Unit | Serializer | host catalog', function (hooks) {
|
||||
name: 'GCP',
|
||||
description: 'this is a GCP plugin host-catalog',
|
||||
type: 'plugin',
|
||||
worker_filter: 'workerfilter',
|
||||
attributes: {
|
||||
disable_credential_rotation: true,
|
||||
project_id: 'project',
|
||||
|
||||
Reference in new issue
Block a user