From ee8063401e0cae55eb3efc4b55944550cad61ae7 Mon Sep 17 00:00:00 2001 From: "Juan Picado @jotadeveloper" Date: Wed, 5 Jul 2017 20:20:30 +0200 Subject: [PATCH] (doc): Upload plugins documentation --- wiki/README.md | 6 +---- wiki/plugins.md | 60 ++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 60 insertions(+), 6 deletions(-) diff --git a/wiki/README.md b/wiki/README.md index abd91464d..ac24aead7 100644 --- a/wiki/README.md +++ b/wiki/README.md @@ -15,13 +15,13 @@ from a fresh look at the code and the outstanding issues. So here we are 🎉 * [Setting up *uplinks*](uplinks.md) * [Packages Access](packages.md) * [Enable Notifications](notifications.md) +* [Installing Plugins](plugins.md) ## Advanced Configurations @@ -42,7 +42,3 @@ from a fresh look at the code and the outstanding issues. So here we are 🎉 * [Ansible](ansible.md) * [Docker](docker.md) - -## Extends Verdaccio - -* [Plugins](plugins.md) diff --git a/wiki/plugins.md b/wiki/plugins.md index 8a5b568c2..aee112aba 100644 --- a/wiki/plugins.md +++ b/wiki/plugins.md @@ -1,4 +1,62 @@ -This is a pre release of plugins compatible with **Verdaccio**. +# Plugins + +Verdaccio is an plugabble aplication. Currently supports multiple plugins only for [Auhtentification](auth.md) but there are plans to [improve the plugin system](https://github.com/verdaccio/verdaccio/issues/169). If you are intested to develop your own plugin, read the [development](development.md) section. + +## Usage + +### Installation + +```bash +$> npm install --global verdaccio-activedirectory +``` +`verdaccio` as a sinopia fork it has backward compability with plugins that are compatible with `sinopia@1.4.0`. In such case the installation is the same. + +``` +&> npm install --global sinopia-memory +``` + +### Configuration + +Open the `config.yaml` file and update the `auth` section as follows: + +The default configuration looks like this, due we use a build-in `htpasswd` plugin by default that you can disable just commenting out the following lines. + +```yaml + htpasswd: + file: ./htpasswd + # Maximum amount of users allowed to register, defaults to "+inf". + # You can set this to -1 to disable registration. + #max_users: 1000 +``` + +and replacing them with (in case you decide to use a `ldap` plugin. + +```yaml +auth: + activedirectory: + url: "ldap://10.0.100.1" + baseDN: 'dc=sample,dc=local' + domainSuffix: 'sample.local' +``` + +### Multiple Auth plugins + +This is tecnically possible, the plugins order becames important, the the credentials will resolved in order. + +```yaml +auth: + htpasswd: + file: ./htpasswd + # Maximum amount of users allowed to register, defaults to "+inf". + # You can set this to -1 to disable registration. + #max_users: 1000 + activedirectory: + url: "ldap://10.0.100.1" + baseDN: 'dc=sample,dc=local' + domainSuffix: 'sample.local' +``` + +This is a list of plugins compatible with **Verdaccio**. ## Sinopia Legacy Plugins