2019-01-02 14:21:36 +00:00
< div >
2019-02-14 02:58:45 +00:00
< div class = "col-sm-12 form-section-title" >
Automatic user provisioning
2019-02-08 15:07:16 +00:00
< / div >
< div class = "form-group" >
< span class = "col-sm-12 text-muted small" >
2020-04-10 21:54:53 +00:00
With automatic user provisioning enabled, Portainer will create user(s) automatically with the standard user role. If disabled, users must be created beforehand in Portainer
in order to login.
2019-02-08 15:07:16 +00:00
< / span >
< / div >
< div class = "form-group" >
2019-02-14 02:58:45 +00:00
< label class = "col-sm-3 col-lg-2 control-label text-left" > Automatic user provisioning< / label >
2020-04-10 21:54:53 +00:00
< label class = "switch" style = "margin-left: 20px;" > < input type = "checkbox" ng-model = "$ctrl.settings.OAuthAutoCreateUsers" / > < i > < / i > < / label >
2019-02-14 02:58:45 +00:00
< / div >
< div ng-if = "$ctrl.settings.OAuthAutoCreateUsers" >
< div class = "form-group" >
< span class = "col-sm-12 text-muted small" >
2019-02-18 03:18:48 +00:00
< p > The users created by the automatic provisioning feature can be added to a default team on creation.< / p >
2020-04-10 21:54:53 +00:00
< p
>By assigning newly created users to a team, they will be able to access the environments associated to that team. This setting is optional and if not set, newly created
users won't be able to access any environments.< /p
>
2019-02-14 02:58:45 +00:00
< / span >
< / div >
< div class = "form-group" >
< label class = "col-sm-3 col-lg-2 control-label text-left" > Default team< / label >
< span class = "small text-muted" style = "margin-left: 20px;" ng-if = "$ctrl.teams.length === 0" >
2020-01-27 01:02:04 +00:00
You have not yet created any teams. Head over to the < a ui-sref = "portainer.teams" > Teams view< / a > to manage teams.
2019-02-14 02:58:45 +00:00
< / span >
2020-04-10 21:54:53 +00:00
< button type = "button" class = "btn btn-sm btn-danger" ng-click = "$ctrl.settings.DefaultTeamID = null" ng-disabled = "!$ctrl.settings.DefaultTeamID" ng-if = "$ctrl.teams.length > 0"
>< i class = "fa fa-times" aria-hidden = "true" > < /i
>< / button >
2019-02-14 02:58:45 +00:00
< div class = "col-sm-9 col-lg-9" ng-if = "$ctrl.teams.length > 0" >
< select class = "form-control" ng-model = "$ctrl.settings.DefaultTeamID" ng-options = "team.Id as team.Name for team in $ctrl.teams" >
< option value = "" > No team< / option >
< / select >
< / div >
2019-02-08 15:07:16 +00:00
< / div >
< / div >
2020-04-10 21:54:53 +00:00
< oauth-providers-selector on-select = "($ctrl.onSelectProvider)" provider = "$ctrl.state.provider" > < / oauth-providers-selector >
2019-01-02 14:24:10 +00:00
2019-01-02 14:21:36 +00:00
< div class = "col-sm-12 form-section-title" > OAuth Configuration< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'microsoft'" >
< label for = "oauth_microsoft_tenant_id" class = "col-sm-3 col-lg-2 control-label text-left" >
Tenant ID
2019-02-25 00:38:27 +00:00
< portainer-tooltip position = "bottom" message = "ID of the Azure Directory you wish to authenticate against. Also known as the Directory ID" > < / portainer-tooltip >
2019-02-14 02:58:45 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
< input
2020-04-10 21:54:53 +00:00
type="text"
class="form-control"
id="oauth_microsoft_tenant_id"
placeholder="xxxxxxxxxxxxxxxxxxxx"
ng-model="$ctrl.state.microsoftTenantID"
ng-change="$ctrl.onMicrosoftTenantIDChange()"
2019-02-14 02:58:45 +00:00
/>
< / div >
< / div >
2019-01-02 14:21:36 +00:00
< div class = "form-group" >
< label for = "oauth_client_id" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-25 00:38:27 +00:00
{{ $ctrl.state.provider.name == 'microsoft' ? 'Application ID' : 'Client ID' }}
2019-02-19 01:38:42 +00:00
< portainer-tooltip position = "bottom" message = "Public identifier of the OAuth application" > < / portainer-tooltip >
2019-01-02 14:21:36 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_client_id" ng-model = "$ctrl.settings.ClientID" placeholder = "xxxxxxxxxxxxxxxxxxxx" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
< div class = "form-group" >
< label for = "oauth_client_secret" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-25 00:38:27 +00:00
{{ $ctrl.state.provider.name == 'microsoft' ? 'Application key' : 'Client secret' }}
2019-01-02 14:21:36 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "password" class = "form-control" id = "oauth_client_secret" ng-model = "$ctrl.settings.ClientSecret" placeholder = "xxxxxxxxxxxxxxxxxxxx" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_authorization_uri" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-19 01:38:42 +00:00
Authorization URL
2019-01-02 14:21:36 +00:00
< portainer-tooltip
2020-04-10 21:54:53 +00:00
position="bottom"
message="URL used to authenticate against the OAuth provider. Will redirect the user to the OAuth provider login view"
2019-01-02 14:21:36 +00:00
>< / portainer-tooltip >
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_authorization_uri" ng-model = "$ctrl.settings.AuthorizationURI" placeholder = "https://example.com/oauth/authorize" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_access_token_uri" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-19 01:38:42 +00:00
Access token URL
2020-04-10 21:54:53 +00:00
< portainer-tooltip position = "bottom" message = "URL used by Portainer to exchange a valid OAuth authentication code for an access token" > < / portainer-tooltip >
2019-01-02 14:21:36 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_access_token_uri" ng-model = "$ctrl.settings.AccessTokenURI" placeholder = "https://example.com/oauth/token" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_resource_uri" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-19 01:38:42 +00:00
Resource URL
2020-04-10 21:54:53 +00:00
< portainer-tooltip position = "bottom" message = "URL used by Portainer to retrieve information about the authenticated user" > < / portainer-tooltip >
2019-01-02 14:21:36 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_resource_uri" ng-model = "$ctrl.settings.ResourceURI" placeholder = "https://example.com/user" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_redirect_uri" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-19 01:38:42 +00:00
Redirect URL
< portainer-tooltip
2020-04-10 21:54:53 +00:00
position="bottom"
message="URL used by the OAuth provider to redirect the user after successful authentication. Should be set to your Portainer instance URL"
2019-02-19 01:38:42 +00:00
>< / portainer-tooltip >
2019-01-02 14:21:36 +00:00
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_redirect_uri" ng-model = "$ctrl.settings.RedirectURI" placeholder = "http://yourportainer.com/" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_user_identifier" class = "col-sm-3 col-lg-2 control-label text-left" >
2019-02-19 01:38:42 +00:00
User identifier
2019-01-02 14:21:36 +00:00
< portainer-tooltip
2020-04-10 21:54:53 +00:00
position="bottom"
message="Identifier that will be used by Portainer to create an account for the authenticated user. Retrieved from the resource server specified via the Resource URL field"
2019-01-02 14:21:36 +00:00
>< / portainer-tooltip >
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_user_identifier" ng-model = "$ctrl.settings.UserIdentifier" placeholder = "id" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name == 'custom' || $ctrl.state.overrideConfiguration" >
2019-01-02 14:21:36 +00:00
< label for = "oauth_scopes" class = "col-sm-3 col-lg-2 control-label text-left" >
Scopes
< portainer-tooltip
2020-04-10 21:54:53 +00:00
position="bottom"
message="Scopes required by the OAuth provider to retrieve information about the authenticated user. Refer to your OAuth provider documentation for more information about this"
2019-01-02 14:21:36 +00:00
>< / portainer-tooltip >
< / label >
< div class = "col-sm-9 col-lg-10" >
2020-04-10 21:54:53 +00:00
< input type = "text" class = "form-control" id = "oauth_scopes" ng-model = "$ctrl.settings.Scopes" placeholder = "id,email,name" / >
2019-01-02 14:21:36 +00:00
< / div >
< / div >
2019-02-14 02:58:45 +00:00
< div class = "form-group" ng-if = "$ctrl.state.provider.name != 'custom'" >
< div class = "col-sm-12" >
< a class = "small interactive" ng-if = "!$ctrl.state.overrideConfiguration" ng-click = "$ctrl.state.overrideConfiguration = true;" >
2019-02-20 21:30:09 +00:00
< i class = "fa fa-wrench space-right" aria-hidden = "true" > < / i > Override default configuration
2019-02-14 02:58:45 +00:00
< / a >
2019-02-21 01:02:25 +00:00
< a class = "small interactive" ng-if = "$ctrl.state.overrideConfiguration" ng-click = "$ctrl.state.overrideConfiguration = false; $ctrl.useDefaultProviderConfiguration()" >
2019-02-17 04:01:36 +00:00
< i class = "fa fa-cogs space-right" aria-hidden = "true" > < / i > Use default configuration
2019-02-14 02:58:45 +00:00
< / a >
< / div >
< / div >
2019-01-02 14:21:36 +00:00
< / div >