Verified Commit ff355beb authored by Chocobozzz's avatar Chocobozzz
Browse files

Add external auth support

parent 3fb4c248
body {
--mainBackgroundColor: black !important;
.header-right {
background-color: black;
}
body {
color: white !important;
.upload-button {
background-color: red !important;
}
......@@ -6,7 +6,8 @@ async function register ({
storageManager,
videoCategoryManager,
videoLicenceManager,
videoLanguageManager
videoLanguageManager,
registerExternalAuth
}) {
const defaultAdmin = 'PeerTube admin'
......@@ -79,6 +80,21 @@ async function register ({
router.post('/form/post/mirror', (req, res) => {
res.json(req.body)
})
{
const result = registerExternalAuth({
authName: 'fake-auth',
authDisplayName: 'fake auth',
onAuthRequest: (req, res) => {
result.userAuthenticated({
req,
res,
username: 'fake_auth_username',
email: 'fake_auth_username@example.com'
})
}
})
}
}
async function unregister () {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment