Update README.md

This commit is contained in:
notplants
2026-01-08 21:13:31 +00:00
parent 9b900f2131
commit acd6d57d83

View File

@ -17,19 +17,70 @@
## Quick start
Note: this recipe requires two domains. One domain for drive, and one for minio which also needs its own public endpoint (see [https://github.com/suitenumerique/drive/issues/476](https://github.com/suitenumerique/drive/issues/476)]). For example (`drive.yourdomain.tld` and `minio.drive.yourdomain.tld` would work).
### Setting Up Domains
This recipe requires four domains. One domain for drive, and one for minio which also needs its own public endpoint (see [https://github.com/suitenumerique/drive/issues/476](https://github.com/suitenumerique/drive/issues/476)]), one domain for collabora, and one domain for onlyoffice. For example (`drive.yourdomain.tld`, `minio.drive.yourdomain.tld`, `collabora.drive.yourdomain.tld`, `onlyoffice.drive.yourdomain.tld`). All of these domains need to have an A record pointing the IP address of your server.
### Installation Steps
* Deploy Single Sign On (see [Authentication](#authentication) below)
* `abra app new lasuite-drive --secrets`
* `abra app config <app-name>`
- make sure to set MINIO_DOMAIN, COLLABORA_DOMAIN, ONLY_OFFICE_DOMAIN to the domains you set up for each.
* `abra app deploy <app-name>`
* `abra app cmd <app-name> backend migrate`
* `abra app restart <app-name> minio-createbuckets` (Note: this will appear to fail, but probably worked! Check `abra app logs <app-name> minio-createbuckets`)
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
You should then be able to visit the landing page of your app, but not yet to login. To login, you need to deploy and integrate single sign on (described below in the "Configure Authentication" section).
## Authentication
Docs **requires** an OpenID Connect (OIDC) single sign-on provider; we recommend [Authentik](https://git.coopcloud.tech/coop-cloud/authentik) or [Keycloak](https://git.coopcloud.tech/coop-cloud/keycloak), both of which are installable using Co-op Cloud.
## Configure Authentication
TODO: add more documentation on how to configure keycloak so oidc secret is integrated.
lasuite-drive **requires** an OpenID Connect (OIDC) single sign-on provider; deployment has been tested with [Keycloak](https://git.coopcloud.tech/coop-cloud/keycloak), which we recommend, or you could also try [Authentik](https://git.coopcloud.tech/coop-cloud/authentik), both of which are installable using Co-op Cloud.
Instructions for integrating keycloak with drive after deploying it, are below.
* In keycloak, create a realm (save the name of this realm, you will need it later)
* Within that realm, create a client
* during client creation, ensure:
- Standard flow: True
- Direct access grants: True
- Authorization: True
- Client authentication: True
- PKCE method: none
* Within the client tab, for your client, click on "Credentials". Click on the the copy button to copy "Client Secret" so you can insert this into your coop cloud deployment in the next step.
* `abra app secret insert <app-name> oidc_rp_client_secret v1 <yoursecret>`
* Now create a user for this client within keycloak. Within the Users tab, click "Add User". Any username and password works. Save this info.
You then additionally need to modify the config of drive to point to your keycloak deployment.
* `abra app config <app-name>`
```
OIDC_REALM=<the realm you configured in keycloak>
AUTH_DOMAIN=<the domain of your keycloak instance>
OIDC_RP_CLIENT_ID=<yourkeycloakclientid>
```
then redeploy drive:
`abra app deploy <app-name> --force`
at this point, when you go to your drive url, you shoud then be able to click "login" and login with the username and password for the user you created in keycloak.
you can make additional users in keycloak for this "client" and they will all be able to login to drive and collaborate.
## Configure E-Mail
Using `abra app config <app-name>` you need to set the following for your smtp server:
```
DJANGO_EMAIL_HOST="yourmailserver.com"
DJANGO_EMAIL_PORT=1025
DJANGO_EMAIL_FROM=noreply@example.com
```
You then need to insert the password for your smtp server as a secret:
`abra app secret insert <app-name> email_pass v1 <youremailpass>`
Then redeploy the app, and automated e-mail sending should work:
`abra app deploy <app-name> --force`