55
66This plugin is used to authenticate in Redmine through an OAuth provider.
77
8- The user is identified by the email registered by the OAuth provider. The email must correspond with an email registered
9- in Redmine. If such an email is not found, the user is ofered with registration to Redmine depending on the Redmine's
10- setting ** Self-registration** .
8+ The user is identified by the email registered with the OAuth provider. The email must match an email registered in Redmine.
9+ If such an email is not found, the user will be offered to register in Redmine, depending on Redmine's setting ** Self-registration** .
1110
1211Inspired by Gucin's plugin https://github.com/Gucin/redmine_omniauth_azure .
1312
@@ -17,7 +16,7 @@ Supported OAuth providers:
1716* GitLab (https://about.gitlab.com )
1817* Google (https://google.com )
1918* Keycloak (https://www.keycloak.org )
20- * Otka (https://www.okta.com )
19+ * Okta (https://www.okta.com )
2120
2221### Installation:
2322
@@ -27,7 +26,7 @@ Supported OAuth providers:
27264 . Install required gems
28275 . Restart the application
2928
30- E .g. Linux + Apache web server
29+ e .g. Linux + Apache web server
3130
3231``` shell
3332cd plugins
@@ -38,42 +37,61 @@ bundle install
3837systemctl restart apache2
3938```
4039
40+ #### Docker installation
41+
42+ 1 . Enter the plugins folder you mount into Docker
43+ 2 . Clone the repository
44+ 3 . Add permission fix and build-essential:
45+ ```
46+ FROM redmine:latest
47+
48+ # Fix permissions for bundle install of bigdecimal for redmine_oauth
49+ RUN chown -R redmine: /usr/local/bundle/ && chmod -R o-w /usr/local/bundle/
50+
51+ # Install build-essential to build dependencies of redmine_oauth
52+ RUN export DEBIAN_FRONTEND=noninteractive \
53+ && apt-get update \
54+ && apt-get install --yes --no-install-recommends build-essential \
55+ && apt-get clean \
56+ && rm -rf /var/lib/apt/lists/*
57+ ```
58+
4159### Registration
4260
43- Register your Redmine instance as an application by your OAuth provider. Follow the instructions given on their web
44- sites. As the redirect URI add https://yourdomain/oauth2callback .
61+ Register your Redmine instance as an application with your OAuth provider. Follow the instructions given on their web
62+ sites. Add ` https://yourdomain/oauth2callback ` as redirect URI .
4563
4664### Configuration
4765
4866Open _ Administration -> Plugins_ in your Redmine and configure the plugin.
4967
5068Examples:
5169
52- #### Provider Azure AD
70+ #### Provider Azure AD
5371
5472* Site: https://login.microsoftonline.com
55- * Client ID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
56- * Client secret: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
57- * Tenant ID / Realm xxxxxxxx-xxx-xxxx-xxxx-xxxxxxxxxxxx
73+ * Client ID: ` xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx `
74+ * Client secret: ` xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx `
75+ * Tenant ID / Realm ` xxxxxxxx-xxx-xxxx-xxxx-xxxxxxxxxxxx `
5876
5977#### Provider Google
6078
6179* Site: https://accounts.google.com
62- * Client ID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
63- * Client secret: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
80+ * Client ID: ` xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx `
81+ * Client secret: ` xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx `
6482
6583#### Provider Keycloak
6684
6785Create a new OIDC Client in your Keycloak Realm. Activate ` Client authentication ` .
6886
69- * Site: https://keycloak.example.com (without any paths)
70- * Client-ID: keycloak.example.com (do not include ` https:// ` or other special characters in the Client ID)
87+ * Site: ` https://keycloak.example.com ` (without any paths)
88+ * Client-ID: ` keycloak.example.com ` (do not include ` https:// ` or other special characters in the Client ID)
7189* Secret: Copy the client secret from Keycloak
7290* Tenant ID: the name of your Keycloak realm
7391
7492### Tasks
7593
76- ## Receive IMAP
94+ #### Receive IMAP
7795Read emails from an IMAP server and process them into Redmine.
7896
7997Available options:
@@ -90,7 +108,9 @@ Available options:
90108
91109Example:
92110
93- ``` rake redmine_oauth:email:receive_imap username='notifications@example.com' RAILS_ENV="production" ```
111+ ``` shell
112+ rake redmine_oauth:email:receive_imap username=' notifications@example.com' RAILS_ENV=" production"
113+ ```
94114
95115** Prior accessing IMAP via OAuth, it is necessary to grant flow to authenticate IMAP connections.**
96116
@@ -100,7 +120,7 @@ https://learn.microsoft.com/en-us/exchange/client-developer/legacy-protocols/how
100120
101121### Uninstallation
102122
103- ```
123+ ``` shell
104124cd plugins
105125rm redmine_oauth
106126```
0 commit comments