ui: Add AWS Lambda as potential external source (#14605)
* ui: Add AWS Lambda as potential external source * Update mocks to expect `lambda` as an external-source meta * Additional mock to make sure all our mocks only contain whats possible
This commit is contained in:
parent
f9b4fa17f1
commit
f658ee9996
|
@ -22,6 +22,7 @@
|
|||
.consul-external-source.vault::before {
|
||||
@extend %with-vault-300;
|
||||
}
|
||||
.consul-external-source.lambda::before,
|
||||
.consul-external-source.aws::before {
|
||||
@extend %with-aws-300;
|
||||
}
|
||||
|
|
|
@ -52,6 +52,7 @@
|
|||
@extend %with-user-team-mask, %as-pseudo;
|
||||
color: rgb(var(--tone-gray-500));
|
||||
}
|
||||
%popover-select .lambda button::before,
|
||||
%popover-select .aws button::before {
|
||||
@extend %with-aws-300;
|
||||
}
|
||||
|
|
|
@ -9,7 +9,16 @@ export function serviceExternalSource(params, hash) {
|
|||
const prefix = typeof hash.prefix === 'undefined' ? '' : hash.prefix;
|
||||
if (
|
||||
source &&
|
||||
['consul-api-gateway', 'vault', 'kubernetes', 'terraform', 'nomad', 'consul', 'aws'].includes(
|
||||
[
|
||||
'consul-api-gateway',
|
||||
'vault',
|
||||
'kubernetes',
|
||||
'terraform',
|
||||
'nomad',
|
||||
'consul',
|
||||
'aws',
|
||||
'lambda'
|
||||
].includes(
|
||||
source
|
||||
)
|
||||
) {
|
||||
|
|
|
@ -97,7 +97,16 @@ ${fake.helpers.randomize([
|
|||
"Precedence": ${i + 1},
|
||||
${ fake.random.number({min: 1, max: 10}) > 2 ? `
|
||||
"Meta": {
|
||||
"external-source": "${fake.helpers.randomize(['kubernetes', 'consul-api-gateway'])}"
|
||||
"external-source": "${fake.helpers.randomize([
|
||||
'consul-api-gateway',
|
||||
'vault',
|
||||
'nomad',
|
||||
'terraform',
|
||||
'kubernetes',
|
||||
'aws',
|
||||
'lambda',
|
||||
''
|
||||
])}"
|
||||
},
|
||||
` : `` }
|
||||
"CreatedAt": "2018-05-21T16:41:27.977155457Z",
|
||||
|
|
|
@ -87,7 +87,16 @@ ${typeof location.search.partition !== 'undefined' ? `
|
|||
${ fake.random.number({min: 1, max: 10}) > 2 ? `
|
||||
"Meta": {
|
||||
"consul-dashboard-url": "${fake.internet.protocol()}://${fake.internet.domainName()}/?id={{Service}}",
|
||||
"external-source": "${fake.helpers.randomize(['consul-api-gateway', 'vault', 'consul', 'nomad', 'terraform', 'kubernetes', 'aws', ''])}"
|
||||
"external-source": "${fake.helpers.randomize([
|
||||
'consul-api-gateway',
|
||||
'vault',
|
||||
'nomad',
|
||||
'terraform',
|
||||
'kubernetes',
|
||||
'aws',
|
||||
'lambda',
|
||||
''
|
||||
])}"
|
||||
},
|
||||
` : `
|
||||
"Meta": null,
|
||||
|
|
|
@ -50,7 +50,16 @@ ${ fake.random.number({min: 1, max: 10}) > 2 ? `
|
|||
range(fake.random.number({min: 1, max: 1})).map(
|
||||
function(item, i)
|
||||
{
|
||||
return `"${fake.helpers.randomize(['vault', 'consul', 'nomad', 'terraform', 'kubernetes', 'aws', ''])}"`;
|
||||
return `"${fake.helpers.randomize([
|
||||
'consul-api-gateway',
|
||||
'vault',
|
||||
'nomad',
|
||||
'terraform',
|
||||
'kubernetes',
|
||||
'aws',
|
||||
'lambda',
|
||||
''
|
||||
])}"`;
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
|
@ -63,7 +63,14 @@ return `
|
|||
],
|
||||
${ fake.random.number({min: 1, max: 10}) > 2 ? `
|
||||
"Meta": {
|
||||
"external-source": "${fake.helpers.randomize(['consul-api-gateway', 'consul', 'nomad', 'terraform', 'kubernetes', ''])}"
|
||||
"external-source": "${fake.helpers.randomize([
|
||||
'consul-api-gateway',
|
||||
'consul',
|
||||
'nomad',
|
||||
'terraform',
|
||||
'kubernetes',
|
||||
''
|
||||
])}"
|
||||
},
|
||||
` : `` }
|
||||
"Address":"",
|
||||
|
|
|
@ -90,7 +90,16 @@ ${ fake.random.number({min: 1, max: 10}) > 2 ? `
|
|||
range(fake.random.number({min: 1, max: 1})).map(
|
||||
function(item, i)
|
||||
{
|
||||
return `"${fake.helpers.randomize(['consul-api-gateway', 'vault', 'nomad', 'terraform', 'kubernetes', 'aws', ''])}"`;
|
||||
return `"${fake.helpers.randomize([
|
||||
'consul-api-gateway',
|
||||
'vault',
|
||||
'nomad',
|
||||
'terraform',
|
||||
'kubernetes',
|
||||
'aws',
|
||||
'lambda',
|
||||
''
|
||||
])}"`;
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
|
@ -5,6 +5,7 @@ brand:
|
|||
nomad: Nomad
|
||||
vault: Vault
|
||||
aws: AWS
|
||||
lambda: AWS Lambda
|
||||
aws-iam: AWS IAM
|
||||
kubernetes: Kubernetes
|
||||
jwt: JWT
|
||||
|
|
Loading…
Reference in New Issue