mirror of https://github.com/rancher/dashboard.git
Merge pull request #3035 from mantis-toboggan-md/bugfix-auth
github style, detailed authz message
This commit is contained in:
commit
b9571efe63
|
|
@ -228,7 +228,7 @@ authConfig:
|
||||||
unrestricted: Allow any valid user
|
unrestricted: Allow any valid user
|
||||||
allowedPrincipalIds:
|
allowedPrincipalIds:
|
||||||
title: Authorized Users & Groups
|
title: Authorized Users & Groups
|
||||||
associatedWarning: 'Note: The {provider} user you authenticate as will be associated as an alternate way to login to the {vendor} user you are currently logged in as (<code>{username}</code>).'
|
associatedWarning: 'Note: The {provider} user you authenticate as will be associated as an alternate way to login to the {vendor} user you are currently logged in as (<code>{username}</code>); all the global permissions, project, and cluster role bindings of this {vendor} user will also apply to the {provider} user.'
|
||||||
github:
|
github:
|
||||||
clientId:
|
clientId:
|
||||||
label: Client ID
|
label: Client ID
|
||||||
|
|
@ -381,6 +381,8 @@ authConfig:
|
||||||
enabled: 'The {provider} authentication provider is currently enabled.'
|
enabled: 'The {provider} authentication provider is currently enabled.'
|
||||||
testAndEnable: Test and Enable Authentication
|
testAndEnable: Test and Enable Authentication
|
||||||
noneEnabled: Local Authentication is always enabled, but you may select another additional authentication provider from those shown below.
|
noneEnabled: Local Authentication is always enabled, but you may select another additional authentication provider from those shown below.
|
||||||
|
localEnabled: '{vendor} is configured to allow access to accounts in its local database.'
|
||||||
|
manageLocal: Manage Accounts
|
||||||
|
|
||||||
authGroups:
|
authGroups:
|
||||||
actions:
|
actions:
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ import LabeledInput from '@/components/form/LabeledInput';
|
||||||
import Banner from '@/components/Banner';
|
import Banner from '@/components/Banner';
|
||||||
import CopyToClipboard from '@/components/CopyToClipboard';
|
import CopyToClipboard from '@/components/CopyToClipboard';
|
||||||
import AllowedPrincipals from '@/components/auth/AllowedPrincipals';
|
import AllowedPrincipals from '@/components/auth/AllowedPrincipals';
|
||||||
import { NORMAN, MANAGEMENT } from '@/config/types';
|
import { MANAGEMENT } from '@/config/types';
|
||||||
import { findBy } from '@/utils/array';
|
import { findBy } from '@/utils/array';
|
||||||
import AuthConfig from '@/mixins/auth-config';
|
import AuthConfig from '@/mixins/auth-config';
|
||||||
import AuthBanner from '@/components/auth/AuthBanner';
|
import AuthBanner from '@/components/auth/AuthBanner';
|
||||||
|
|
@ -69,10 +69,6 @@ export default {
|
||||||
return `${ this.model.tls ? 'https://' : 'http://' }${ this.model.hostname }`;
|
return `${ this.model.tls ? 'https://' : 'http://' }${ this.model.hostname }`;
|
||||||
},
|
},
|
||||||
|
|
||||||
principal() {
|
|
||||||
return this.$store.getters['rancher/byId'](NORMAN.PRINCIPAL, this.$store.getters['auth/principalId']) || {};
|
|
||||||
},
|
|
||||||
|
|
||||||
displayName() {
|
displayName() {
|
||||||
return this.t(`model.authConfig.provider.${ NAME }`);
|
return this.t(`model.authConfig.provider.${ NAME }`);
|
||||||
},
|
},
|
||||||
|
|
@ -170,7 +166,7 @@ export default {
|
||||||
:labels="[ t(`authConfig.${NAME}.target.public`), t(`authConfig.${NAME}.target.private`)]"
|
:labels="[ t(`authConfig.${NAME}.target.public`), t(`authConfig.${NAME}.target.private`)]"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row mb-20">
|
||||||
<div class="col span-6">
|
<div class="col span-6">
|
||||||
<LabeledInput
|
<LabeledInput
|
||||||
v-if="!isPublic"
|
v-if="!isPublic"
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,16 @@ export default {
|
||||||
|
|
||||||
displayName() {
|
displayName() {
|
||||||
return this.$store.getters['type-map/labelFor'](this.schema, 2);
|
return this.$store.getters['type-map/labelFor'](this.schema, 2);
|
||||||
}
|
},
|
||||||
|
|
||||||
|
localUsersRoute() {
|
||||||
|
return {
|
||||||
|
name: 'c-cluster-product-resource',
|
||||||
|
params: {
|
||||||
|
cluster: this.$route.params.cluster, product: 'auth', resource: MANAGEMENT.USER
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
|
@ -67,7 +76,7 @@ export default {
|
||||||
params: { id },
|
params: { id },
|
||||||
query: { [MODE]: _EDIT }
|
query: { [MODE]: _EDIT }
|
||||||
});
|
});
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -77,7 +86,14 @@ export default {
|
||||||
<h1 class="m-0">
|
<h1 class="m-0">
|
||||||
{{ displayName }}
|
{{ displayName }}
|
||||||
</h1>
|
</h1>
|
||||||
<Banner v-if="!enabled.length" :label="t('authConfig.noneEnabled')" color="info" />
|
<Banner v-if="!enabled.length" :label="t('authConfig.noneEnabled')" color="info">
|
||||||
|
{{ t('authConfig.localEnabled') }}
|
||||||
|
<nuxt-link :to="localUsersRoute">
|
||||||
|
{{ t('authConfig.manageLocal') }}
|
||||||
|
</nuxt-link>
|
||||||
|
<br />
|
||||||
|
{{ t('authConfig.noneEnabled') }}
|
||||||
|
</Banner>
|
||||||
<SelectIconGrid
|
<SelectIconGrid
|
||||||
:rows="rows"
|
:rows="rows"
|
||||||
:color-for="colorFor"
|
:color-for="colorFor"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue