mirror of
https://github.com/strapi/strapi.git
synced 2025-07-24 17:40:18 +00:00
36 lines
842 B
JavaScript
36 lines
842 B
JavaScript
'use strict';
|
|
|
|
// eslint-disable-next-line node/no-extraneous-require
|
|
const { features } = require('@strapi/strapi/lib/utils/ee');
|
|
const executeCEBootstrap = require('../../server/bootstrap');
|
|
const { getService } = require('../../server/utils');
|
|
|
|
const SSO_ACTIONS = [
|
|
{
|
|
uid: 'provider-login.read',
|
|
displayName: 'Read',
|
|
pluginName: 'admin',
|
|
section: 'settings',
|
|
category: 'single sign on',
|
|
subCategory: 'options',
|
|
},
|
|
{
|
|
uid: 'provider-login.update',
|
|
displayName: 'Update',
|
|
pluginName: 'admin',
|
|
section: 'settings',
|
|
category: 'single sign on',
|
|
subCategory: 'options',
|
|
},
|
|
];
|
|
|
|
module.exports = async () => {
|
|
const { actionProvider } = getService('permission');
|
|
|
|
if (features.isEnabled('sso')) {
|
|
await actionProvider.registerMany(SSO_ACTIONS);
|
|
}
|
|
|
|
await executeCEBootstrap();
|
|
};
|