Search this page for the topic you are looking for
11 |
Use the navigation to browse this Admin Manual
12 |
13 |
14 | If you fell you need our help, don't hesitate to post a new topic in our
15 | community forum.
16 |
17 |
18 | {% endblock %}
19 |
--------------------------------------------------------------------------------
/docs/installation/components/zabbix.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Zabbix Monitoring
6 |
7 | Install Zabbix Agent and Zabbix Server on the same host to monitor system status.
8 |
9 | ## Get the Zabbix Server:
10 |
11 | After installation, you can get access to the zabbix server webinterface
12 |
13 | - Login to Zabbix Server Browser: `https://:6235`
14 |
15 | Initial Login with: Admin/zabbix
16 |
17 | ## After login:
18 |
19 | Go to `Monitoring > Hosts`. Change Host Configuration of **Zabbix server** :
20 |
21 | From: IP 127.0.0.1
22 | To: DNS zabbix-agent
23 |
24 | After some seconds the monitoring will run and deliver data.
25 |
--------------------------------------------------------------------------------
/docs/installation/advanced/http-only.md:
--------------------------------------------------------------------------------
1 | # Force http only for your SeaTable Server
2 |
3 | ## Force http during installation
4 |
5 | It is not recommended to run SeaTable without https. Still it is possible. During the installation it is sufficient to set the .env variable `SEATABLE_SERVER_PROTOCOL` with the value `http` and all configuration files and caddy will be set up correctly.
6 |
7 | ## Switching after the installation
8 |
9 | If you want to force http after the initial setup, you also have to adapt these configuraton files and replace all https:// values with http://:
10 |
11 | - dtable_web_settings.py
12 | - ccnet.conf
13 | - nginx.conf
14 |
15 | Especially the change of the nginx file is not trivial, if you don't have any experience with nginx.
16 |
--------------------------------------------------------------------------------
/docs/customization/manual-in-nav.md:
--------------------------------------------------------------------------------
1 | # Custom manual
2 |
3 | By default SeaTable presents a "Manual" link on its home page. Starting with version v4.4 this link points to but in all former versions, the link opened only a blank new browser tab.
4 |
5 | 
6 |
7 | Luckily it is super easy to change the behaviour of this manual link and to change the target URL.
8 |
9 | ## Setup the target URL of the manual link
10 |
11 | Open the configuration file `dtable_web_settings.py` located at `/opt/seatable-server/seatable/conf/` and add this configuration line. Change the value to your needs.
12 |
13 | ```bash
14 | HELP_LINK = 'https://help.seatable.com/'
15 | ```
16 |
17 | Don't forget to restart SeaTable service.
18 |
--------------------------------------------------------------------------------
/overrides/partials/integrations/analytics/matomo.html:
--------------------------------------------------------------------------------
1 |
18 |
--------------------------------------------------------------------------------
/docs/maintenance/password-reset.md:
--------------------------------------------------------------------------------
1 | # Password Reset
2 |
3 | #### User Management
4 |
5 | When you setup SeaTable, you should have setup a admin account. After you logged in a admin, you may add/delete users.
6 |
7 | #### Resetting User Password
8 |
9 | Administrator can reset password for a user in "System Admin" page.
10 |
11 | In a private server, the default settings doesn't support users to reset their password by email. If you want to enable this, you have first to [set up notification email](../configuration/sending-email.md).
12 |
13 | #### Forgot Admin Account or Password?
14 |
15 | You may create a new admin account from the command line. Use these commands and follow the instructions on the screen.
16 |
17 | ```bash
18 | docker exec -it seatable-server bash
19 | seatable.sh superuser
20 | ```
21 |
22 | After logging in the new admin account, you can reset the original admin account's password.
23 |
--------------------------------------------------------------------------------
/docs/maintenance/repair-base.md:
--------------------------------------------------------------------------------
1 | # Repair/Prune a base from the command line
2 |
3 | SeaTable provides a repair script that can be executed from the command line to fix/repair typical problems with a base:
4 |
5 | - Ensures that every table has a column with the ID `0000`
6 | - Removes all rows and views without an ID
7 |
8 | In addition, the repair script prunes the base by removing the content of deleted columns from the JSON object to reduce the size of the base, thus avoiding the 200MB limit.
9 |
10 | This can free up quite a lot of space if you have deleted columns with lots of values since deleting a column **does not** immediately remove the _column values_ from the JSON object. Instead, only the _column definition_ is removed.
11 |
12 | For the execution you need the `base_uuid`.
13 |
14 | ```
15 | docker exec -it seatable-server bash
16 | cd /templates
17 | seatable.sh python-env /opt/seatable/seatable-server-latest/dtable-web/manage.py repair_base
18 | ```
19 |
--------------------------------------------------------------------------------
/docs/configuration/authentication/two-factor-auth.md:
--------------------------------------------------------------------------------
1 | # Two-Factor Authentication
2 |
3 | Two-factor authentication (2FA) provides an extra layer of security against unauthorized access by requiring an additional piece of information besides **username and password**.
4 |
5 | SeaTable supports time-based, one-time passwords (TOTP) as a second factor with the default authentication.
6 |
7 | A TOTP app such as Google Authenticator or [2FAS](https://2fas.com/) is required to use 2FA with SeaTable.
8 |
9 | ## Global Configuration
10 |
11 | To enable 2FA, add the following configuratiaon in the configuration file `dtable_web_settings.py`:
12 |
13 | ```
14 | ENABLE_TWO_FACTOR_AUTH = True # Default value is False.
15 | ```
16 |
17 | Optionally, 2FA can be enforced for for all users. If you wish to do that, add the following configuration to `dtable_web_settings`:
18 |
19 | ```
20 | ENABLE_FORCE_2FA_TO_ALL_USERS = True # Defaule value is False.
21 | ```
22 |
23 | Note: When disabling 2FA enforcement by changing `True` to `False`, 2FA is disabled for all users.
24 |
25 | ## User-specific Configuration
26 |
27 | System and team administrators can enforce 2FA for individual users in system and team administration of SeaTable's web interface, respectively.
28 |
--------------------------------------------------------------------------------
/docs/configuration/user-hierarchy/teams-organizations.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Teams / Organizations (like in cloud.seatable.io)
6 |
7 | Teams / Organizations is a feature mainly for bigger installations where groups of people should be completely separated. In fact, cloud.seatable.io uses this feature to separate the teams from each other. The users of a team can see each other, but other users are invisible for them.
8 |
9 | Besides Teams, SeaTable offers also deparments and groups. This article is focusing on teams only.
10 |
11 | !!! question "Are Teams and Organizations the same?"
12 |
13 | Teams and organizations can be considered as the same. Organization is the name of the function and therefore used in the configuration files but in cloud.seatable.io we used this function to separate accounts from each other and there we call it **teams**. In short:
14 |
15 | - organization is the technical term.
16 | - teams is the marketing term.
17 |
18 | ## How to configure teams
19 |
20 | You have to add these two settings in `dtable_web_settings.py`.
21 |
22 | ```bash
23 | CLOUD_MODE = True
24 | MULTI_TENANCY = True
25 | ```
26 |
27 | Please be aware that this activates a whole bunch of settings and restrictions. These are ...
28 |
--------------------------------------------------------------------------------
/docs/configuration/autostart.md:
--------------------------------------------------------------------------------
1 | # Autostart
2 |
3 | ## Autostart of the docker container
4 |
5 | In all our `yml` files, we have specified `restart: unless-stopped`. The function specifies that the container should always restart if it exits for any reason—except if it was explicitly stopped by a user or administrator. This policy keeps your container running persistently unless you intentionally stop it.
6 |
7 | ## Autostart of SeaTable service
8 |
9 | When you start the SeaTable Docker container, the SeaTable service and all its components launch automatically. There are only a few exceptions where this does not happen, such as when specific advanced configurations are in place:
10 |
11 | ## Deactivate Autostart
12 |
13 | There are situations under which the SeaTable service does not start automatically:
14 |
15 | 1. you set the `.env` Variable `SEATABLE_START_MODE=cluster`
16 | 2. there is a `seatable-controller.conf` in the `conf` directory
17 |
18 | In both cases SeaTable expects to be part of an advanced setup where the service should not be started automatically. So if SeaTable service does not start automatically, check first, if one of these two situations are true.
19 |
20 | Otherwise check the logs of your container with `docker logs seatable-server`.
21 |
--------------------------------------------------------------------------------
/docs/introduction/get-support.md:
--------------------------------------------------------------------------------
1 | # Get support
2 |
3 | Next to this administration manual there are more documentations available. To learn more about how to use SeaTable as a user, how to use the SeaTable API, the possibilities to develop your own plugins or scripts in SeaTable, please refer to their respective manuals:
4 |
5 | - [SeaTable User Manual](https://help.seatable.com)
6 | - [SeaTable Developer Manual](https://developer.seatable.com)
7 | - [SeaTable API Reference](https://api.seatable.com)
8 |
9 | See the [official SeaTable channel](https://youtube.com/seatable) on YouTube for tutorials, guides and overviews. Visit [our blog](https://seatable.com/blog/) for latest news and to learn more about what is going on in and around SeaTable.
10 |
11 | At any time you could have a look at the SeaTable [Community Forum](https://forum.seatable.com) to share your experience with other users or report issues or bugs.
12 |
13 | !!! success "Enterprise support"
14 |
15 | If you're using SeaTable in your organization and need
16 | assistance, e.g., to __digitalization of processes__, __develop custom solutions__ or __improve efficiency__,
17 | [__get in touch__](mailto:sales@seatable.io) to discuss our __enterprise support__ offerings.
18 |
19 | We're happy to help!
20 |
--------------------------------------------------------------------------------
/docs/customization/site-title.md:
--------------------------------------------------------------------------------
1 | # Site Title and Site Name
2 |
3 | **Site Title** and **Site Name** are two basic customization options. The **Title** is used in the browser tab and the **Name** is used in notifications or email messages.
4 |
5 | 
6 |
7 | !!! warning "Web interface overrule config files"
8 |
9 | Please be aware that if you define a value in the webinterface, this always overrules the value in the config file.
10 |
11 | ## Configuration via the web interface
12 |
13 | Login to your SeaTable Server as system administrator and switch to the system admin area. Select the navigation point `Settings`. Team admins or normal users does not have the permission to access the system admin area.
14 |
15 | 
16 |
17 | Add a new **Title** and/or **Name** and save the values. The changes are live right away.
18 |
19 | ## Configuration via config file
20 |
21 | Add these configurations to `dtable_web_settings.py` and restart SeaTable service.
22 |
23 | ```bash
24 | # Browser tab's title
25 | SITE_TITLE = 'Private SeaTable'
26 |
27 | # Set this to your website/company's name.
28 | # The title is used in email notifications and welcome messages.
29 | SITE_NAME = 'SeaTable'
30 | ```
31 |
--------------------------------------------------------------------------------
/docs/installation/components/uptime-kuma.md:
--------------------------------------------------------------------------------
1 | # Uptime Kuma
2 |
3 | This guide shows how to activate Uptime Kuma on a one node seatable server.
4 |
5 | ## Installation
6 |
7 | ### Change the .env file
8 |
9 | Add _uptime-kuma.yml_ to the COMPOSE_FILE variable.
10 |
11 | ```bash
12 | nano /opt/seatable-compose/.env
13 | ```
14 |
15 | Your COMPOSE_FILE variable should look something like this:
16 |
17 | ```bash
18 | COMPOSE_FILE='seatable-docker-proxy.yml,seatable-server.yml,uptime-kuma.yml'
19 | ```
20 |
21 | ### Update the compose project
22 |
23 | ```bash
24 | cd /opt/seatable-compose && \
25 | docker compose up -d
26 | ```
27 |
28 | ### Configure your Uptime Kuma
29 |
30 | Your Uptime Kuma Container provides a Web UI to set up your Uptime Kuma Admin User under `https://:6230`.
31 |
32 | ## Things to monitor of your seatable server
33 |
34 | Paths:
35 |
36 | - https://deploy.seatable-demo.de/api2/ping/
37 | - https://deploy.seatable-demo.de/dtable-server/ping/
38 | - ...
39 | - https://deploy.seatable-demo.de:6231/healthz (n8n)
40 | - https://deploy.seatable-demo.de:6232/ (collabora online)
41 | - https://deploy.seatable-demo.de:6233/welcome/ (onlyoffice)
42 | - ...
43 |
44 | ## Screenshots
45 |
46 | will be added shortly.
47 |
48 |
51 |
--------------------------------------------------------------------------------
/docs/configuration/gunicorn-py.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Configuration of Gunicorn
6 |
7 | Gunicorn is used within the SeaTable Docker container as the WSGI server that runs the main web application and API processes (account endpoints). It sits between the web server **nginx** and the SeaTable Python code, efficiently handling concurrent user requests and ensuring robust performance.
8 |
9 | !!! success "Typically no changes are necessary!"
10 |
11 | SeaTable automatically configures Gunicorn with optimal settings for most deployments. Adjustments are only required in advanced scenarios, such as customizing performance, logging, or security settings. For most administrators, the default configuration ensures secure and efficient operation.
12 |
13 | ## Example configuration
14 |
15 | A typical Gunicorn configuration file is created automatically by SeaTable during the first startup:
16 |
17 | ```
18 | daemon = True
19 | workers = 5
20 | threads = 5
21 |
22 | # default localhost:8000
23 | bind = '127.0.0.1:8000'
24 |
25 | # Pid
26 | pidfile = '/opt/seatable/pids/dtable-web.pid'
27 |
28 | # for file upload, we need a longer timeout value (default is only 30s, too short)
29 | timeout = 1200
30 |
31 | limit_request_line = 8190
32 |
33 | # Log
34 | #accesslog = '/opt/seatable/logs/gunicorn-access.log'
35 | #errorlog = '/opt/seatable/logs/gunicorn-error.log'
36 | ```
37 |
--------------------------------------------------------------------------------
/docs/customization/favicon.md:
--------------------------------------------------------------------------------
1 | # Replace Favicon in SeaTable
2 |
3 | SeaTable allows you to easily replace the default SeaTable favicon with a custom one. SeaTable uses two favicons: a default one { width="24"} and a notification favicon { width="24" } that appears when you have unread notifications.
4 |
5 | ## Configuration via the Web Interface
6 |
7 | Currently, it is not possible to replace these favicons through the system administrator interface.
8 |
9 | ## Configuration via the Command Line
10 |
11 | Instead of uploading favicons via the web interface, you must save them on the host using the command line. Simply save your favicons to the following paths and restart your container:
12 |
13 | - `/opt/seatable-server/seatable/seahub-data/custom/seatable-favicon.ico`
14 | - `/opt/seatable-server/seatable/seahub-data/custom/seatable-notification.ico`
15 |
16 | If the `custom` directory does not exist, you will need to create it.
17 |
18 | ### Custom Path
19 |
20 | If you prefer to use a different file name, you can modify this by adding the following settings to `dtable_web_settings.py`. The path must be publically available and is therefore relative to the media path. SeaTable supports both `png` and `ico` files.
21 |
22 | ```python
23 | CUSTOM_FAVICON_PATH = 'custom/my-favicon.png'
24 | CUSTOM_FAVICON_NOTIFICATION_PATH = 'custom/my-notification-favicon.png'
25 | ```
26 |
--------------------------------------------------------------------------------
/docs/installation/start.md:
--------------------------------------------------------------------------------
1 | # Introduction to SeaTable Server Installation
2 |
3 | SeaTable is the world leading self hosted no-code platform. You can run SeaTable on consumer or enterprise-grade hardware and a variety of operating systems and architectures. The installation always uses Docker and the docker compose plugin. This guide outlines the installation process for SeaTable Server (Enterprise and Developer Edition) on a Linux OS using Docker.
4 |
5 | Our goal is to offer a straightforward installation method that results in a fully operational SeaTable system accessible via HTTPS within minutes. While the steps have been tested on Debian and Ubuntu-based systems, they should also work on other Linux server systems. The installation is executed via the command line as the `root` user.
6 |
7 | Before You Begin: [Review the requirements](../introduction/requirements.md).
8 |
9 | You can deploy SeaTable-Server in one of the following topologies:
10 |
11 | ## Single-Node Deployment
12 |
13 | - Easy installation with docker and docker compose.
14 | - Ideal for testing purposes or smaller teams for up to 100 users.
15 |
16 | [Start the installation](./basic-setup.md){ .md-button .md-button--primary } [Our deployment approach](./deployment-approach.md){ .md-button }
17 |
18 | ## Cluster Deployment
19 |
20 | - Enterprise-grade high-performance no-code platform.
21 | - Maximum performance and scalability for thousands of users.
22 |
23 | [Read more about Cluster](./cluster/introduction.md){ .md-button }
24 |
--------------------------------------------------------------------------------
/docs/introduction/editions.md:
--------------------------------------------------------------------------------
1 | # SeaTable Server Editions
2 |
3 | There are two editions of SeaTable Server available for self hosting.
4 |
5 | - **Enterprise Edition**: almost no limitation for storage, row numbers and API calls and have advanced permissions and user management features. It is meant for large teams to use SeaTable in both ways. Users can use it in the cloud or self-hosted.
6 |
7 | - **Developer Edition**: for users that want to use SeaTable as database and heavily using APIs and scripts. The developer edition has no limit on storage, row numbers and API calls, but can support at most 200 concurrent connections to dtable-server.
8 |
9 | ## License and limitation of SeaTable Developer Edition
10 |
11 | The services of SeaTable Server (both editions) are released under the following licenses:
12 |
13 | - dtable-web: Apache License v2
14 | - dtable-events: Apache License v2
15 | - dtable-server: [Proprietary License](dtable-server-license.md)
16 | - seaf-server: AGPLv3
17 |
18 | SeaTable developer edition should not be used to provide SaaS service or as a part of your SaaS service. Other kinds of usage are okay, including
19 |
20 | - Personal or home use
21 | - Internal in-house use
22 | - Collaboration with customers
23 | - IT projects for customers, as long as a separate server is used for each customer
24 |
25 | ## License and limitations of SeaTable Enterprise Edition
26 |
27 | The SeaTable Enterprise Edition is released under a proprietary license. You find the EULA at .
28 |
--------------------------------------------------------------------------------
/docs/customization/logo.md:
--------------------------------------------------------------------------------
1 | # Logo
2 |
3 | The Logo of your SeaTable server can easily be replaced via the web interface or the command line.
4 |
5 | ## Configuration via the web interface
6 |
7 | Login to your SeaTable Server as system administrator and switch to the system admin area. Select the navigation point `Settings`.
8 |
9 | 
10 |
11 | Click an `Change` and select a new image file with the recommended resolution of 256\*64 px. After a page reload the new logo is visible.
12 |
13 | It is recommended that your logo has a transparent background because it is used on the login-page, emails and also the web interface.
14 |
15 | SeaTable will save the logo as `mylogo.png` on the server at `/opt/seatable-server/seatable/seahub-data/custom/`.
16 |
17 | ## Configuration via the command line
18 |
19 | Instead of upload the logo via the webinterface, you could also create the logo file via the command line. SeaTable expects that you generate a file called `mylogo.png` in the directory `/opt/seatable-server/seatable/seahub-data/custom/`.
20 | The directory `custom` does not exist in general, therefore you might have to create it first.
21 |
22 | ```bash
23 | mkdir /opt/seatable-server/seatable/seahub-data/custom/
24 | cp mylogo.png /opt/seatable-server/seatable/seahub-data/custom/mylogo.png
25 | ```
26 |
27 | If your logo is not immediately visible after a page reload, you have to restart the SeaTable container (not the SeaTable service).
28 | The SeaTable container has to create a symlink to make the logo file available to SeaTable.
29 |
--------------------------------------------------------------------------------
/docs/customization/overview.md:
--------------------------------------------------------------------------------
1 | # UI Customiziation in SeaTable
2 |
3 | SeaTable Server offers numerous options for tailoring the system to your specific needs. This includes customization of colors, logos, images, emails and HTML templates. While most customization tasks can be performed via the command line interface, system administrators also have the ability to make certain changes directly through the web interface.
4 |
5 | Let's explore the various possibilities for UI customization
6 |
7 | 
8 |
9 | ## Where to find the configuration files?
10 |
11 | You don't have to switch to the SeaTable docker container, to make changes at the configuration files. The configuration files of a SeaTable server can usually be found in the host server at the directory `/opt/seatable-server/seatable/conf/`.
12 |
13 | Use the editor of your choice like `nano` or `vim` to edit the files.
14 |
15 | ## How to persist changes
16 |
17 | Please be aware that any change that you do inside a docker container will be removed if the changes files are not mounted to the host system.
18 | Also changes should never be done in the directory `seatable-server-latest`. This folder will always be replaced as soon as you upgrade to another version.
19 |
20 | Keep this in mind, but the articles will explain precisely where you should do the changes.
21 |
22 | ## How to restart SeaTable?
23 |
24 | Changes in the configuration files, require a restart of the SeaTable container or the SeaTable service.
25 | Read [here, how to restart SeaTable or the complete container](../maintenance/restart-seatable.md).
26 |
--------------------------------------------------------------------------------
/docs/customization/customize-email-notifications.md:
--------------------------------------------------------------------------------
1 | # Customize Email Notifications
2 |
3 | **Note:** Subject line may vary between different releases, this is based on Release 2.0.1. Restart Seahub so that your changes take effect.
4 |
5 | ## User reset his/her password ##
6 |
7 | **Subject**
8 |
9 | seahub/seahub/auth/forms.py line:103
10 |
11 | **Body**
12 |
13 | seahub/seahub/templates/registration/password_reset_email.html
14 |
15 | Note: You can copy password_reset_email.html to `seahub-data/custom/templates/registration/password_reset_email.html` and modify the new one. In this way, the customization will be maintained after upgrade.
16 |
17 | ## System admin add new member ##
18 |
19 | **Subject**
20 |
21 | seahub/seahub/views/sysadmin.py line:424
22 |
23 | **Body**
24 |
25 | seahub/seahub/templates/sysadmin/user_add_email.html
26 |
27 | Note: You can copy user_add_email.html to `seahub-data/custom/templates/sysadmin/user_add_email.html` and modify the new one. In this way, the customization will be maintained after upgrade.
28 |
29 | ## System admin reset user password ##
30 |
31 | **Subject**
32 |
33 | seahub/seahub/views/sysadmin.py line:368
34 |
35 | **Body**
36 |
37 | seahub/seahub/templates/sysadmin/user_reset_email.html
38 |
39 | Note: You can copy user_reset_email.html to `seahub-data/custom/templates/sysadmin/user_reset_email.html` and modify the new one. In this way, the customization will be maintained after upgrade.
40 |
41 | ## User send file/folder share link ##
42 |
43 | **Subject**
44 |
45 | seahub/seahub/share/views.py line:668
46 |
47 | **Body**
48 |
49 | seahub/seahub/templates/shared_link_email.html
50 |
51 |
--------------------------------------------------------------------------------
/docs/maintenance/restart-seatable.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Restarting the SeaTable service
6 |
7 | Changes in the configuration files, require a restart of the SeaTable service.
8 |
9 | ## Method 1: Restart from outside the container
10 |
11 | To restart the SeaTable service directly from your host command line, use:
12 |
13 | ```bash
14 | docker exec seatable-server /opt/seatable/scripts/seatable.sh
15 | ```
16 |
17 | This command runs the SeaTable startup script inside the container, managing all necessary service processes. You must specify the full path to `seatable.sh` because the Docker exec command does not use the container’s `PATH` environment variable by default.
18 |
19 | ## Method 2: Restart from inside the container
20 |
21 | Alternatively, you can open an interactive shell inside the container and run the script manually:
22 |
23 | ```bash
24 | docker exec -it seatable-server bash
25 | seatable.sh
26 | exit
27 | ```
28 |
29 | When using an interactive shell, you do not need to specify the full path to `seatable.sh` because the container’s `PATH` is available. After restarting the service, type `exit` to leave the container shell.
30 |
31 | # Restarting the docker container
32 |
33 | Alternatively, you can restart the complete SeaTable Docker container. This is useful if you need to ensure all processes and services inside the container are refreshed.
34 |
35 | You need to vavigate to your SeaTable compose directory (commonly `/opt/seatable-compose`), then run:
36 |
37 | ```bash
38 | /opt/seatable-compose
39 | docker stop seatable-server
40 | docker compose up -d
41 | ```
42 |
43 | This will stop the SeaTable container and then restart it in detached mode. All related services defined in your `docker-compose.yml` will also be managed according to your configuration.
--------------------------------------------------------------------------------
/docs/maintenance/secrets.md:
--------------------------------------------------------------------------------
1 | # Secrets Management
2 |
3 | ## SECRET_KEY
4 |
5 | During initialization, SeaTable generates a `SECRET_KEY` and saves this random string to the configuration file `dtable_web_settings.py`.
6 |
7 | This `SECRET_KEY` serves two critical functions:
8 |
9 | 1. Generating user sessions
10 | 2. Encrypting "thirdparty account passwords"
11 |
12 | !!! warning "Changing the SECRET_KEY"
13 |
14 | It is strongly discouraged to change the `SECRET_KEY` after initial setup. Modifying it will result in:
15 |
16 | - "Thirdparty accounts" becoming inaccessible
17 | - All current user sessions becoming invalid
18 |
19 | If you absolutely must change the `SECRET_KEY`, follow these steps:
20 |
21 | 1. Delete all thirdparty accounts from all bases
22 | 2. Stop SeaTable
23 | 3. Change the `SECRET_KEY`
24 | 4. Restart SeaTable
25 | 5. All users will need to log in again
26 | 6. Create new thirdparty accounts as needed
27 |
28 | ## PRIVATE_KEY
29 |
30 | !!! success "Configured via environment variable since 5.3"
31 | **Starting with v5.3**, this secret should be provided via environment variable `JWT_PRIVATE_KEY` in your `/opt/seatable-compose/.env` file. There is no need to keep the two variables in your configuration files.
32 |
33 | ??? warning "Configured in configuration files before 5.3"
34 |
35 | SeaTable generates a `PRIVATE_KEY` during initialization for secure inter-component communication between dtable-web and dtable-server/dtable-db. This key is used in two configuration files and must be identical:
36 |
37 | 1. `dtable_server_config.json`: as `private_key`
38 | 2. `dtable_web_settings.py`: as `DTABLE_PRIVATE_KEY`
39 |
40 | If you update this `PRIVATE_KEY`, always ensure that these PRIVATE_KEY values match across both configuration files to maintain proper system functionality.
41 |
--------------------------------------------------------------------------------
/docs/customization/custom-css.md:
--------------------------------------------------------------------------------
1 | # Custom CSS
2 |
3 | SeaTable provides the flexibility to incorporate custom CSS code, allowing users to either conceal specific elements or modify their behavior. This article showcases several examples of what you can achieve with CSS customization.
4 |
5 | ## How to add custom CSS
6 |
7 | Custom css can be added as system admin via the browser of via the command line.
8 | Please refer to the article [main color](../customization/main-color.md) to get an explanation how to add custom css code.
9 |
10 | 
11 |
12 | ## Examples of custom CSS
13 |
14 | ### Example: Switching Column Selection to a Single Row
15 |
16 | If you've transitioned from using to a self-hosted system, you may have noticed a difference in how new columns are added. SeaTable Cloud presents the available column types in a single-row list, while your self-hosted server displays them in a two-row box.
17 |
18 | **Two-Row Selection in a Self-Hosted Server**
19 |
20 | 
21 |
22 | **Single-Row Selection, as in SeaTable Cloud**
23 |
24 | 
25 |
26 | To achieve a single-row display like in SeaTable Cloud, add the following CSS styles:
27 |
28 | ```bash
29 | .select-column-popover .select-column-list .select-column-title {display:none;}
30 | .select-column-popover .select-column-list {display:block !important;}
31 | .select-column-popover .select-column-list .select-column-item {width:100% !important;}
32 | .mobile-editor-column .select-column-container .am-list-header {display:none;}
33 | ```
34 |
--------------------------------------------------------------------------------
/.github/workflows/mkdocs-deploy.yml:
--------------------------------------------------------------------------------
1 | name: Deploy mkdocs to github pages
2 |
3 | on:
4 | push:
5 | branches:
6 | - main
7 | pull_request:
8 | branches:
9 | - main
10 |
11 | env:
12 | GO_VERSION: 1.24.1
13 | MUFFET_VERSION: v2.10.7
14 |
15 | jobs:
16 | check-links:
17 | name: Check links
18 | runs-on: ubuntu-22.04
19 | steps:
20 | - name: Checkout repository
21 | uses: actions/checkout@v4
22 | - uses: actions/setup-go@v2
23 | with:
24 | go-version: ${{ env.GO_VERSION }}
25 | - name: Start development server
26 | run: ./preview.sh
27 | - name: Add $GOPATH/bin to $PATH
28 | run: |
29 | echo "$(go env GOPATH)/bin" >> "$GITHUB_PATH"
30 | - name: Install muffet
31 | run: go install github.com/raviqqe/muffet/v2@${MUFFET_VERSION}
32 | - name: Check links
33 | run: muffet -t60 -c10 -f -i 'http://127*' -i 'http://localhost' http://127.0.0.1:8000
34 | deploy:
35 | runs-on: ubuntu-latest
36 | needs:
37 | - check-links
38 | if: github.ref == 'refs/heads/main'
39 | steps:
40 | - uses: actions/checkout@v4
41 | with:
42 | fetch-depth: 0
43 |
44 | - uses: actions/setup-python@v4
45 | with:
46 | python-version: 3.x
47 |
48 | - name: install
49 | run: pip install -r requirements.txt
50 |
51 | - name: version
52 | run: mkdocs --version
53 |
54 | - name: build
55 | run: mkdocs build --verbose --strict
56 | env:
57 | MKDOCS_GIT_COMMITTERS_APIKEY: ${{ secrets.MKDOCS_GIT_COMMITTERS_APIKEY }}
58 | CI: true
59 |
60 | - name: gh-deploy
61 | run: mkdocs gh-deploy --force
62 | env:
63 | MKDOCS_GIT_COMMITTERS_APIKEY: ${{ secrets.MKDOCS_GIT_COMMITTERS_APIKEY }}
64 | CI: true
65 |
--------------------------------------------------------------------------------
/docs/configuration/base-rows-limit.md:
--------------------------------------------------------------------------------
1 | # Base supported rows limit
2 |
3 | By default, a base contains up to 100,000 rows (excluding archived rows). Above 100,000 rows, the base will become read-only. If more than 150,000 rows, the base will fail to load.
4 |
5 | Base rows are limited for the following technical reasons:
6 |
7 | * The base is read from the persistent storage (dtable-storage-server) into the memory of dtable-server, and the maximum support size is 600M. This is a limitation of Node.js technology, because a string in Node.js cannot exceed 600M. For safety reason, dtable-server will not attempt to load this base when it exceeds 300M. (Attachments in the base are not counted.)
8 | * When the base is too large, it takes too much time for the server to serialize it and send it to the network when the client loads the base. At this time, the server cannot respond to other requests.
9 |
10 | Starting from version 3.4, for private deployment users, if your application scenario needs to support more than 100,000 rows in a base, but the storage space occupied by the base itself is not large (for example, it contains a large number of blank cells), you can modify the server's configuration, to support more than 100,000 rows.
11 |
12 | #### dtable-server
13 |
14 | `dtable_server_config.json`
15 |
16 | ```
17 | {
18 | "base_writable_limit": 100000,
19 | "base_max_rows_limit": 150000
20 | }
21 | ```
22 |
23 | Among them, base_writable_limit is used to limit the rows written into the base. base_max_rows_limit is used to control when the rows in the base is greater than the number, the server refuses to load the base into memory. base_max_rows_limit needs to be greater than base_writable_limit.
24 |
25 | #### dtable-web
26 |
27 | `dtable_web_settings.py`
28 |
29 | ```
30 | BASE_WRITABLE_LIMIT = 100000
31 | ```
32 |
33 | This is used to let the Web UI to become read-only when rows exceed the limit.
34 |
--------------------------------------------------------------------------------
/docs/introduction/server-changelog.md:
--------------------------------------------------------------------------------
1 | # SeaTable Changelog
2 |
3 | SeaTable, as a dynamic platform, undergoes frequent updates and enhancements to provide users with the best possible experience. To keep our users informed about these changes, we maintain several changelogs:
4 |
5 | ## Functions
6 |
7 | For a comprehensive overview of updates to the SeaTable Server, users can refer to our detailed changelog available at [SeaTable Server Changelog](https://seatable.com/changelog/). Here, they can explore the latest features, improvements, and bug fixes implemented in each release, ensuring they stay up-to-date with the platform's evolution.
8 |
9 | ## Blog with Release Notes
10 |
11 | In addition to the detailed changelogs mentioned above, we curate a blog featuring [release notes](https://seatable.com/blog/) that highlight the most significant changes in each version. This narrative-style format provides users with a concise yet informative overview of key updates, allowing them to quickly grasp the impactful enhancements introduced in a particular release. You can explore our blog at SeaTable Release Notes Blog.
12 |
13 | ## New API Calls
14 |
15 | As the SeaTable API evolves to meet the changing needs of our users and developers, we document all new API calls and changes in our [API Changelog](https://api.seatable.com/reference/changelog). This resource, available at SeaTable API Changelog, provides developers with insights into the latest API updates, enabling them to leverage new functionalities and enhancements in their integrations and applications.
16 |
17 | ## Extra Upgrade Notices
18 |
19 | In addition to general changelogs, we provide specific [upgrade notices](../upgrade/extra-upgrade-notice.md) containing changes relevant to administrators. These notices highlight critical updates, potential impact on system configurations, and any necessary actions to ensure smooth transitions during upgrades.
20 |
--------------------------------------------------------------------------------
/docs/installation/advanced/seatable-ai-token-pricing.md:
--------------------------------------------------------------------------------
1 | # AI Token Pricing
2 |
3 | ## AI Credits
4 |
5 | AI credits serve as an internal unit of currency for measuring AI-related usage within SeaTable.
6 | They are directly linked to the number of tokens consumed by using AI-based features according to the [configured price](#pricing-configuration) of each AI model.
7 |
8 | SeaTable supports role-based AI credit limits by configuring the `ai_credit_per_user` option on a user role.
9 | Please refer to the documentation on [user quotas](../../configuration/roles-and-permissions.md#user-quotas) for more details.
10 |
11 | !!! note "`ai_credit_per_user` for organization users"
12 | AI credits are shared across all users inside a SeaTable organization. The total number of credits can be calculated by multiplying the value of `ai_credit_per_user` by the number of team users.
13 |
14 | **Example:** Setting `ai_credit_per_user` to `2` will allow a team with 10 members to have 20 AI credits in total.
15 |
16 | ## Pricing Configuration
17 |
18 | In order to accurately track the number of AI credits used by users and organizations, you must configure token pricing inside `/opt/seatable-server/seatable/conf/dtable_web_settings.py`.
19 | This can be achieved by configuring the `AI_PRICES` variable, which is a dictionary that maps model identifiers (e.g `gpt-4o-mini`) to token pricing **per thousand tokens**:
20 |
21 | ```py
22 | AI_PRICES = {
23 | "gpt-4o-mini": {
24 | "input_tokens_1k": 0.01827, # price / 1000 tokens
25 | "output_tokens_1k": 0.07309 # price / 1000 tokens
26 | },
27 | }
28 | ```
29 |
30 | !!! warning "Model Identifiers"
31 | The dictionary key must match **the exact value** of the chosen AI Model, which is configured through the `SEATABLE_AI_LLM_MODEL` variable inside your `.env` file.
32 | In case of a mismatch, AI usage will not count towards any configured credit limits!
33 |
--------------------------------------------------------------------------------
/docs/configuration/nginx-conf.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Configuration of Nginx
6 |
7 | SeaTable automatically generates a default `nginx.conf` file in the configuration folder. **Since version 5.3, we no longer use this file.**
8 |
9 | The reason for this change is that SeaTable updates often require modifications to the `nginx.conf` file to support new features. These changes are not customer-specific and can complicate the update process. To simplify updates and ensure stable, maintainable configurations, we now provide a custom `nginx.conf` file together with the YAML configuration files. This custom file, located in the compose folder (`/opt/seatable-compose`), is mounted into the container at startup.
10 |
11 | **As a result, the `nginx.conf` file in the container’s configuration folder is obsolete.**
12 |
13 | ## Customizing Nginx Configuration
14 |
15 | When you update SeaTable, all default files in `/opt/seatable-compose` will be overwritten. This includes all changes that you may do in `nginx.conf` and `seatable-server.yml`. To preserve your custom configurations, follow these steps:
16 |
17 | 1. **Create Custom Copies:**
18 | Make a copy of the `nginx.conf` and `seatable-server.yml` files, for example as `custom-nginx.conf` and `custom-seatable-server.yml` in your compose folder (`/opt/seatable-compose`).
19 |
20 | 2. **Edit the Custom Files:**
21 | Make any necessary changes to your custom configuration files.
22 | **Note:** All future modifications should be made to these custom files, not the original files.
23 |
24 | 3. **Update the .env File:**
25 | In your `.env` file, update the `COMPOSE_FILES` variable to include your `custom-seatable-server.yml` file.
26 |
27 | After making changes, [restart the SeaTable container](../maintenance/restart-seatable.md) for your changes to take effect.
28 |
29 | This ensures that your custom configuration is used instead of the original files.
--------------------------------------------------------------------------------
/docs/installation/advanced/seafile.md:
--------------------------------------------------------------------------------
1 | # Integrate with Seafile
2 |
3 |
4 |
5 |
6 | When integrating SeaTable and Seafile, users can add files from Seafile libraries in file columns.
7 |
8 | ### Scope of the Connection
9 |
10 | The Seafile connection to SeaTable enables you to
11 |
12 | - Choose a file as attachment from the Seafile library in SeaTable
13 | - Save attachments in a SeaTable base to your Seafile library (WIP)
14 |
15 | ### How to Setup the Connection on SeaTable Server Side
16 |
17 | - Go to Seafile and generate an API token for your library
18 | - Go to SeaTable and click on the 3-dots menu inside a base, go to Third party integration > Seafile and enter the full URL (including “http” or “https”) and the API token and then submit.
19 |
20 | ### Requirements on the Seafile Server Side
21 |
22 | The cross-domain permissions must be set. This can be done by adding the "Access-Control-Allow-Origin" header.
23 |
24 | Add the following code block to the configuration file `seafile.conf` in `/etc/nginx/sites-available/` or `seafile.nginx.conf` in `/etc/nginx/sites-enabled` (the exact filename and path depend on your Seafile version and installation method):
25 |
26 | ```
27 | location / {
28 | add_header Access-Control-Allow-Origin *;
29 | if ($request_method = 'OPTIONS') {
30 | add_header Access-Control-Allow-Origin *;
31 | add_header Access-Control-Allow-Methods GET,POST,PUT,DELETE,OPTIONS;
32 | add_header Access-Control-Allow-Headers "deviceType,token, authorization, content-type";
33 | return 204;
34 | }
35 |
36 | proxy_pass http://127.0.0.1:8000;
37 | ...............
38 |
39 | ```
40 |
41 | ### Current Limitations
42 |
43 | - Only a single library can be linked to a specific base
44 | - The base editor does not display thumbnails for images stored inside an external Seafile library
45 | - Image columns are not supported yet
46 |
--------------------------------------------------------------------------------
/docs/installation/advanced/seatable-ai-prerequisites.md:
--------------------------------------------------------------------------------
1 |
2 |
3 | # Prerequisites
4 |
5 | This following guides assume that you have a fully functioning [SeaTable Server installation](../basic-setup.md) and have successfully installed [SeaTable AI](../components/seatable-ai.md).
6 |
7 | !!! warning "LLMs are resource-intensive"
8 |
9 | Running an LLM requires significant computing resources.
10 | While the exact requirements depend on the chosen model, our internal tests have shown that LLMs with less than 8 billion parameters do not yield useful results for the use cases we looked at.
11 | Therefore, we recommend that you choose a model with **at least 8-12 billion parameters**.
12 | Generally speaking, this will require **at least 16GB of VRAM** (or more, depending on the configured context window size).
13 | While you can run AI models on a CPU, performance (measured in tokens per second) will be much worse compared to running the same model on a powerful GPU.
14 |
15 | ## GPU Usage
16 |
17 | !!! note "Requirements depend on your GPU make/model"
18 |
19 | You can refer to [Ollama's documentation](https://github.com/ollama/ollama/blob/main/docs/docker.md) for instructions regarding GPU usage.
20 | Depending on your GPU, this will require installing proprietary NVIDIA drivers and the NVIDIA Container Toolkit or adding additional arguments to the `.yml` files shown in the following guides.
21 |
22 | For **Debian**-based systems with **NVIDIA** GPUs, the following steps were carried out to successfully deploy [Ollama](./ollama.md) and [vLLM](./vllm.md):
23 |
24 | 1. Install the proprietary NVIDIA drivers. The [Debian Wiki](https://wiki.debian.org/NvidiaGraphicsDrivers) contains installation instructions for the latest Debian releases.
25 | 2. Remember to restart your system before proceeding with the following steps.
26 | 3. Install the [NVIDIA Container Toolkit](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html).
27 |
--------------------------------------------------------------------------------
/docs/installation/components/seadoc.md:
--------------------------------------------------------------------------------
1 | # Report Design (seadoc)
2 |
3 |
4 |
5 |
6 | SeaDoc is a Docker container required for the new SeaTable **Report Design** plugin. With this plugin, you can easily create multi-page technical reports, summaries, and other documents.
7 |
8 | !!! example "Currently in Beta"
9 |
10 | The **Report Design** plugin is currently in beta. We welcome your feedback. The official release is planned for version 6.0.
11 |
12 | ## Installation Requirements
13 |
14 | 1. SeaTable Enterprise Edition installed and running
15 | 2. Firewall configured to allow traffic on port 6240
16 | 3. System admin to install both the report design plugin and this seadoc editor (server component)
17 |
18 | ## SeaDoc Installation
19 |
20 | Follow these steps to deploy the seadoc editor on the same node as the seatable-server:
21 |
22 | #### Update .env file
23 |
24 | Like with all additional components you need to add `seadoc.yml` to the `COMPOSE_FILE` variable in your `.env` file.
25 |
26 | Simply copy and paste (:material-content-copy:) the following code into your command line:
27 |
28 | ```bash
29 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,seadoc.yml'/" /opt/seatable-compose/.env
30 | ```
31 |
32 | #### Launch the seadoc editor
33 |
34 | Simply run the following commands to (re-)start SeaTable and seadoc container.
35 |
36 | ```bash
37 | cd /opt/seatable-compose && \
38 | docker compose up -d
39 | ```
40 |
41 | #### Verify Installation
42 |
43 | After a few seconds, check `https://:6240`. You should see:
44 |
45 | ```
46 | Welcome to sdoc-server. The current version is ...
47 | ```
48 |
49 | This confirms that the `seadoc` container is operational. If you don't see this message, check that port 6240 is allowed and the container logs.
50 |
51 | ## Final Steps
52 |
53 | With the server-side installation finished, you can now install the **report design plugin** from the SeaTable admin interface and start using this powerful reporting tool.
54 |
--------------------------------------------------------------------------------
/generate-css.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | set -euo pipefail
4 |
5 | echo_color() {
6 | local RED='\033[32m'
7 | local RESET='\033[0m'
8 | echo -e "${RED}$1${RESET}"
9 | }
10 |
11 | if [[ -z "${1-}" ]]; then
12 | echo_color "No Tag parameter detected, using 'seatable-enterprise:latest'"
13 | SEATABLE_VERSION='latest'
14 | else
15 | echo_color "Input parameter detected, using 'seatable/seatable-enterprise:${1}'"
16 | SEATABLE_VERSION="$1"
17 | fi
18 |
19 | echo_color "If you want to use another tag, please stop the execution and restart again with '$0 '."
20 | echo_color "The script will continue in 5 seconds..."
21 | sleep 5
22 |
23 | echo "... let's go"
24 | echo "... Download SeaTable Container"
25 | # Concat CSS files from container
26 | docker run --rm -it --pull=always --quiet "seatable/seatable-enterprise:${SEATABLE_VERSION}" find /opt/seatable/seatable-server-latest/dtable-web/media ! -name 'fontawesome*.css' ! -name 'bootstrap*.css' -name '*.css' -exec cat {} \; > ./custom.css
27 |
28 | echo "... create initial custom.css"
29 | # Manipulate custom.css
30 | docker run --rm --quiet -v $(pwd):/app/ --workdir /app php:8.2-cli php /app/manipulate-css.php custom.css
31 |
32 | echo "... sort + remove duplicates (Set LC_ALL to 'C' to make sorting identical to dedupelist.com)"
33 | LC_ALL=C sort -u -o custom.css custom.css
34 |
35 | echo "... remove '#header' and '.tables-tabs-container' rules, otherwise the base header always has the same color"
36 | sed -i -e '/^#header/d' -e '/^\.tables-tabs-container/d' custom.css
37 |
38 | echo "... remove duplicate a {...} rules (especially with font-weight: bold)"
39 | sed -i -e '/^a.*font-weight: bold/d' -e '/^a{text-decoration-skip:ink;color:##maincolor##}/d' custom.css
40 |
41 | echo "... remove '.btn-outline-primary', otherwise the button color when creating apps is gone"
42 | sed -i '/^.btn-outline-primary{color:##maincolor##;border-color:##maincolor##}/d' custom.css
43 |
44 | echo "... Remove comments"
45 | sed -i 's|/\* 3 seatable common style \*/||' custom.css
46 |
47 | echo "... finish"
48 |
--------------------------------------------------------------------------------
/docs/installation/advanced/air-gap-installation.md:
--------------------------------------------------------------------------------
1 | # Air gap installation
2 |
3 | Air gap installation means that your SeaTable server has no connection to the internet and runs air gapped on the local network. This is feasable for high-security environments but it should be obvious that such a setup requires additional configurations and is not an easy task.
4 |
5 | This article is a summary of the topics that should be considered.
6 |
7 | ## Problems that arise with air gap:
8 |
9 | - Certificate management (HTTPS/TLS) is complicated.
10 | - A separate container registry is necessary.
11 | - A local APT repository is necessary.
12 | - Plugins have to be installed manually.
13 |
14 | Let's go into the details.
15 |
16 | ### Certificate Management
17 |
18 | The easiest solution would be to just use HTTP for all communication but this contradicts the idea of increased security of an air gapped setup. Therefore it is necessary that you use a **globally trusted wildcard certificate**. This is quite easy to obtain but will cost some money. This manual explains how to use such a custom root certificate.
19 |
20 | ### Separate container registry
21 |
22 | Usually SeaTable Server and the other containers are downloaded from [Docker Hub](https://hub.docker.com/r/seatable/seatable-enterprise/). If your SeaTable server has no connection to the internet you need to provide a local container repository like [Quay](https://quay.io) or [Harbor](https://goharbor.io).
23 |
24 | The installation, configuration and usage of such a repository if far beyond the scope of this manual.
25 |
26 | ### Separate local APT repository.
27 |
28 | To keep your linux base system up-to-date and to install docker and other software components, you have to provide a local APT repository. This is also not part of this manual to explain how this works.
29 |
30 | ### Plugins
31 |
32 | This is the most easy part because SeaTable provides a way that you download the Plugins as ZIP files to your local PC and then you can upload it from the local network. Read [this article](../../configuration/plugins.md) for more details.
33 |
--------------------------------------------------------------------------------
/docs/installation/advanced/maintenance-mode.md:
--------------------------------------------------------------------------------
1 | # Maintenance Mode
2 |
3 | Sometimes updates or changes in the configuration are necessary, and it's important to limit access to the server during this period. Enabling maintenance mode ensures that only dedicated IP addresses can access the server, while all other users see a simple maintenance page with a `503 Service Unavailable` status code.
4 |
5 | ## Enabling Maintenance Mode
6 |
7 | Here's how to configure such a maintenance page using Caddy:
8 |
9 | 1. Go to `/opt/seatable-compose/`
10 | 2. Create a copy of your `seatable-server.yml` and name it `maintenance.yml`
11 | 3. Replace the current labels of your SeaTable Server with the following labels.
12 | 4. Replace `` with one IP adresses, that should have access to your server.
13 | 5. Open your `.env` file and replace `seatable-server.yml` with `maintenance.yml` (in the variable `COMPOSE_FILE`)
14 | 6. Run `docker compose up -d`
15 |
16 | ```
17 | ...
18 | labels:
19 | caddy: ${SEATABLE_SERVER_PROTOCOL:-https}://${SEATABLE_SERVER_HOSTNAME:?Variable is not set or empty}
20 | caddy.@blocked: 'not remote_ip private_ranges'
21 | caddy.respond: '@blocked "SeaTable Cloud is currently undergoing maintenance. The service will be restored shortly. Thank you for your patience." 503'
22 | caddy.header.Retry-After: 3600
23 | caddy.reverse_proxy: "{{upstreams 80}}"
24 | ...
25 | ```
26 |
27 | ## How does maintenance look like
28 |
29 | If you are accessing your system from an IP address that has been specified in your labels, you can continue using SeaTable as usual.
30 |
31 | All other users will see a maintenance page displaying the following message:
32 |
33 | 
34 |
35 | ## Disable Maintenance Mode
36 |
37 | To disable maintenance mode, update your `.env` file by replacing `maintenance.yml` with `seatable-server.yml`. Then, run the command:
38 |
39 | ```
40 | docker-compose up -d
41 | ```
42 |
43 | Your SeaTable server will once again be accessible to all users.
44 |
--------------------------------------------------------------------------------
/docs/installation/advanced/ollama.md:
--------------------------------------------------------------------------------
1 |
2 |
3 | # Ollama
4 |
5 | [Ollama](https://docs.ollama.com/) is a framework that allows you to run various LLMs (Large Language Models) on your own hardware.
6 |
7 | !!! warning "Ollama vs vLLM"
8 |
9 | This guides showcases a **very basic** Ollama deployment meant for trying out a self-hosted LLM deployed on the same server as SeaTable itself.
10 | You should take a look at [vLLM](./vllm.md) in case you plan on deploying a **production-ready** LLM inference/serving engine.
11 | Compared to Ollama, vLLM provides much better performance when handling concurrent requests.
12 |
13 | ## Instructions
14 |
15 | ### Create `ollama.yml`
16 |
17 | Create `/opt/seatable-compose/ollama.yml` with the following contents:
18 |
19 | ```yaml
20 | services:
21 | ollama:
22 | image: ollama/ollama:0.11.10
23 | restart: unless-stopped
24 | container_name: ollama
25 | # Comment out the following line if you don't have a GPU
26 | gpus: all
27 | networks:
28 | - backend-seatable-net
29 | volumes:
30 | - /opt/ollama:/root/.ollama
31 | ```
32 |
33 | Afterwards, you should add `ollama.yml` to the `COMPOSE_FILE` variable inside your `.env` file:
34 |
35 | ```bash
36 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,ollama.yml'/" /opt/seatable-compose/.env
37 | ```
38 |
39 | ### Configuration
40 |
41 | In order to use Ollama to execute AI-based automation steps inside SeaTable, you must add the following configuration settings to your `.env` file:
42 |
43 | ```ini
44 | SEATABLE_AI_LLM_TYPE='ollama_chat'
45 | SEATABLE_AI_LLM_URL='http://ollama:11434'
46 | # Choose a model: https://ollama.com/library
47 | SEATABLE_AI_LLM_MODEL='gemma3:12b'
48 | ```
49 |
50 | ### Start Ollama
51 |
52 | You can now start Ollama by running `docker compose up -d` inside `/opt/seatable-compose`.
53 |
54 | In addition, it is necessary to manually download the chosen AI model by executing the following command **once**:
55 |
56 | ```bash
57 | docker exec -it ollama ollama pull $MODEL
58 | ```
59 |
60 | You are now able to run AI-based automations steps inside SeaTable via your local Ollama deployment!
61 |
--------------------------------------------------------------------------------
/docs/installation/advanced/python-pipeline-workflow.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Workflow of the Python Pipeline in a nutshell
6 |
7 | This is a short explanation what happens, if you click on "Run script" inside SeaTable.
8 |
9 | ## SeaTable Server
10 |
11 | To initialize the Python Pipeline, SeaTable-Server makes a POST request to the API-endpoint `/run-script/` of the scheduler. This call is authenticated by the shared secret, defined in `dtable_web_settings.py`. Every two seconds (and for max. 15 minutes), the SeaTable Server checks the status of the script execution by calling `/run-script/` from the scheduler.
12 |
13 | ## SeaTable Scheduler
14 |
15 | The scheduler creates a new task in the mariadb database. The scheduler calls the API-endpoint `/function/run-python` of the starter. Now the scheduler waits for the starter's POST request to `/script-result/`, which indicates that the run has finished. The scheduler then writes the duration and the output to the database.
16 |
17 | ## SeaTable Starter
18 |
19 | The starter downloads the python script directly from SeaTable Server and saves the script to a temporary folder on the hard drive of the host. The starter now starts a python-runner container and mounts the script as input. After completion the runner container is deleted and the result data is sent to the scheduler by making a POST request to `/script-result/`.
20 |
21 | ## SeaTable Runner
22 |
23 | SeaTable runner executes the python script and writes the output to the same temporary folder on the host. After that the container stops.
24 |
25 | ## Important points
26 |
27 | - dtable-web only queries the result as long as the browser is open (manual execution).
28 | - if an automation starts a python script, SeaTable Server waits max. 15 minutes for the run to finish.
29 | - starter and runner communicate via the exchange directory. this must be available as a volume to both containers
30 | - starter and scheduler communicate via api calls.
31 | - the python runner is stopped after 15 minutes at the latest
32 | - the scheduler has a cleanup process to invalidate work orders in the database that run for longer than 15 minutes.
33 | - the task is stored in the database for some days (30 days by default)
34 |
--------------------------------------------------------------------------------
/docs/installation/advanced/webserver-security.md:
--------------------------------------------------------------------------------
1 | # Security settings
2 |
3 | ## Accept headers
4 |
5 | Our default deployment enforces strict security headers, which prevent the loading of images or scripts from external URLs. This approach is designed to enhance security and protect against fraudulent activities.
6 |
7 | If you are running your own server, you have the option to modify these security headers to allow additional sites to interact with your SeaTable server.
8 |
9 | To adjust these settings, you can modify the `seatable-server.yml` file located at `/opt/seatable-compose/seatable-server.yml`. The default configuration might look like this:
10 |
11 | ```
12 | caddy.header.Content-Security-Policy: "`
13 | block-all-mixed-content;
14 | default-src 'none';
15 | style-src 'unsafe-inline' 'self';
16 | script-src 'unsafe-inline' 'unsafe-eval' 'self';
17 | script-src-elem 'unsafe-inline' 'self' ${SEATABLE_SERVER_HOSTNAME}:${ONLYOFFICE_PORT:-6233} maps.googleapis.com;
18 | font-src 'self' data:;
19 | img-src 'self' data: blob: https: market.seatable.io mt0.google.com maps.googleapis.com maps.gstatic.com;
20 | form-action 'self' ${SEATABLE_SERVER_HOSTNAME}:${COLLABORA_PORT:-6232};
21 | connect-src 'self' market.seatable.io https:;
22 | frame-src 'self' ${SEATABLE_SERVER_HOSTNAME}:${COLLABORA_PORT:-6232} ${SEATABLE_SERVER_HOSTNAME}:${ONLYOFFICE_PORT:-6233};
23 | frame-ancestors 'self';
24 | worker-src 'self' blob:;
25 | manifest-src 'self';
26 | object-src 'self';
27 | base-uri 'self'
28 | `"
29 | ```
30 |
31 | Create a custom copy of your `seatable-server.yml` file and modify these settings according to your specific requirements. Don't forget to link the new yml file in your `.env` file.
32 |
33 | ## Cookies
34 |
35 | !!! important "Secure cookies require additional configuration"
36 |
37 | To get these ratings, it is required to add two more options to `dtable_web_settings.py`. In one of the next versions, these parameters will probably be added by default.
38 |
39 | ```bash
40 | CSRF_COOKIE_SECURE = True
41 | SESSION_COOKIE_SECURE = True
42 | ```
43 |
44 | ## DNSSEC
45 |
46 | It also requires DNSSEC from your domain hoster to get the best security measures.
47 |
--------------------------------------------------------------------------------
/docs/installation/advanced/additional-subdomains.md:
--------------------------------------------------------------------------------
1 | # Additional Subdomain
2 |
3 | By default SeaTable and all additional components use one single public available domain. This manual explains what to do if you want to make an additional component like n8n available via (sub)domain instead of a port. This article describes the necessary change to the existing caddy container. If you want to use a complete different proxy, please refer the the article ...
4 |
5 | ## Typical configuration
6 |
7 | Look at `n8n.yml` to get an understanding of how caddy is configured to make n8n accessable via port 6231.
8 |
9 | ```bash
10 | services:
11 | caddy:
12 | ports:
13 | - ${N8N_PORT:-6231}:${N8N_PORT:-6231} # <-- enhances caddy.yml
14 |
15 | n8n-postgres:
16 | ...
17 |
18 | n8n:
19 | ...
20 | ```
21 |
22 | In the n8n.yml we add an additional port to the caddy container by adding an additional port. Imagine you use seatable.example.com to access SeaTable, then port 443 is routed to SeaTable and port 6231 is routed to the n8n container.
23 |
24 | ## New configuration to use a custom domain
25 |
26 | The following example assumes that you want to access n8n not anymore via the port 6231 but with the URL `n8n.example.com`.
27 |
28 | 1. Make a copy of the n8n.yml and name it e.g. custom-n8n.yml.
29 | 2. Replace n8n.yml with custom-n8n.yml in your .env in COMPOSE_FILE.
30 | 3. Replace the caddy part of the custom-n8n.yml in this way.
31 |
32 | ```bash
33 | services:
34 | caddy:
35 | labels:
36 | caddy: n8n.example.com
37 | caddy.reverse_proxy: "{{upstream 6231}}"
38 | ```
39 |
40 | This configures caddy to proxy all requests to n8n.example.com to the port 6231, in this case n8n.
41 |
42 | Restart all docker containers with the following command to enforce this new setting.
43 |
44 | !!! danger "All containers have to be restarted"
45 |
46 | It is not sufficient to restart only the container that should use a separate domain. The caddy container has to be restarted to. `docker compose` will not detect any change of the caddy.yml, therefore we recommend to stop and restart all containers with these commands.
47 |
48 | ```bash
49 | cd /opt/seatable-compose && \
50 | docker compose down && \
51 | docker compose up -d
52 | ```
53 |
--------------------------------------------------------------------------------
/docs/installation/components/gatus.md:
--------------------------------------------------------------------------------
1 | # Gatus
2 |
3 | [Gatus](https://github.com/TwiN/gatus) provides your users with a real-time status page for your SeaTable Server and alerts you if any core components become unreachable. By default Gatus monitors the following components:
4 |
5 | - SeaTable Login Page
6 | - SeaTable API Gateway
7 | - MariaDB
8 | - Redis
9 | - Certificate Expiration
10 | - Python Pipeline
11 |
12 | {style="border-radius:12px; padding:16px; background-color:#020817"}
13 |
14 | ## Installation
15 |
16 | This guide explains how to install **Gatus** on your SeaTable server.
17 |
18 | #### Change the .env file
19 |
20 | As with other additional components, first add `gatus.yml` to the `COMPOSE_FILE` variable in your `.env` file.
21 |
22 | Copy and paste (:material-content-copy:) the following command into your terminal:
23 |
24 | ```bash
25 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,gatus.yml'/" /opt/seatable-compose/.env
26 | ```
27 |
28 | #### Start Gatus
29 |
30 | To start Gatus for the first time, run:
31 |
32 | ```
33 | cd /opt/seatable-compose && \
34 | docker compose up -d
35 | ```
36 |
37 | #### Verify the setup
38 |
39 | Open `https:///status` or `https://:6220` in your browser to check if your new status page is accessible. This page will monitor your main components in real time. To reach this page, you must open/expose the port 6220 in your firewall.
40 |
41 | ## E-Mail notifications
42 |
43 | Email notifications are preconfigured. You only need to provide the following environment variables in your `.env` file:
44 |
45 | ```
46 | GATUS_EMAIL_USERNAME=
47 | GATUS_EMAIL_PASSWORD=
48 | GATUS_EMAIL_HOST=
49 | GATUS_EMAIL_PORT=
50 | GATUS_EMAIL_FROM=
51 | GATUS_EMAIL_TO=
52 | ```
53 |
54 | Each variable is self-explanatory.
55 |
56 | ## Additional Notifications and Advanced Configuration
57 |
58 | Gatus uses two configuration files: `/opt/seatable-compose/gatus.yml` and `/opt/seatable-compose/config/gatus-config.yml`.
59 |
60 | To ensure your changes persist after updates, create copies of these files (e.g., custom-....yml) and update the references accordingly.
61 |
62 | For all available configuration options, see the [Gatus GitHub repository](https://github.com/TwiN/gatus).
63 |
64 |
--------------------------------------------------------------------------------
/docs/maintenance/big-data-cleanup.md:
--------------------------------------------------------------------------------
1 | # Big Data Cleanup
2 |
3 |
4 |
5 | Unused or deleted big data storage is not automatically reclaimed. To free up disk space for bases that use large amounts of big data storage, run the following commands as needed.
6 |
7 | ## Detecting Bases with Large Big Data Storage
8 |
9 | Check the size of the folders stored in `/opt/seatable-server/seatable/db-data`.
10 | Using the `ncdu` tool is recommended, as it shows the storage usage per folder.
11 |
12 | Example output:
13 |
14 | ```
15 | --- /opt/dtable-db/seatable/db-data ------------------------------------------
16 | 135.4 MiB [##########################] /9ba24950-cd00-42dc-b5e9-233f3de2c2b6
17 | 54.0 MiB [########## ] /281b15c1-2a12-4da3-814d-145cb703a55b
18 | 40.5 MiB [####### ] /76a4c7e8-2422-4c3f-9282-40e1e9fd5afc
19 | 33.3 MiB [###### ] /35a51052-0f29-4628-91f3-9aad177e1bd2
20 | 33.1 MiB [###### ] /52fd3b11-d00f-4fdf-b2ce-d306e08c4697
21 | 30.4 MiB [##### ] /9220dada-2a6a-4392-8dee-0d77af0f5a02
22 | 28.9 MiB [##### ] /3adc3d74-1783-40a9-9d05-245e9dc03f21
23 | ```
24 |
25 | Each folder name corresponds to the UUID of a base.
26 |
27 | ## Garbage Collection for Big Data
28 |
29 | Run garbage collection on a base to remove unused or deleted big data entries:
30 |
31 | ```bash
32 | docker exec -it seatable-server bash
33 | cd /opt/seatable/seatable-server-latest/
34 | ./dtable-db-admin.sh gc ""
35 | ```
36 |
37 | Replace `` with the actual UUID of the base.
38 |
39 | This command reclaims unreferenced data blocks and cleans up invalid references in the big data store.
40 |
41 | ## Flatten Command
42 |
43 | After running garbage collection, you may see log warnings such as:
44 |
45 | ```
46 | Unable to read: Key: xxx, file with ID not found
47 | ```
48 |
49 | These messages can appear during backup operations. To clean up remaining invalid keys, run the flatten command:
50 |
51 | ```bash
52 | ./dtable-db-admin.sh flatten ""
53 | ```
54 |
55 | !!! note "Archived keys and values are stored in separate files in `dtable-db`"
56 |
57 | The warning occurs when garbage collection removes value files but leaves behind invalid key entries.
58 | This does not affect data integrity and is primarily an internal maintenance issue.
59 |
--------------------------------------------------------------------------------
/docs/installation/advanced/database-standalone.md:
--------------------------------------------------------------------------------
1 | # Standalone Database
2 |
3 | Managed Database is an often used managed service. SeaTable can easily be configured to use a separate database. We recommend to initialize SeaTable with the default mariadb container. Then dump the database, load the dump to a separate database, update the `.env` file and restart SeaTable. Due to this assumption, this manual is the same for a new SeaTable Server or a service where you want to migrate the database.
4 |
5 | ## Stop SeaTable
6 |
7 | ```bash
8 | docker stop seatable-server
9 | ```
10 |
11 | Now you can be sure, that no more records are written or modified in the database.
12 |
13 | ## Dump and restore to another database
14 |
15 | Please refer to [Backup and Recovery](../../maintenance/backup-recovery.md#mariadb-database) for instructions regarding the backup process for the MariaDB database.
16 |
17 | You can use the `mariadb` CLI to import the contents of the dumped databases into the managed databases.
18 |
19 | ## Stop Mariadb
20 |
21 | After the dump, stop also the database container:
22 |
23 | ```bash
24 | docker stop mariadb
25 | ```
26 |
27 | ## Don't start mariadb container
28 |
29 | Create a copy of `seatable-server.yml` and rename it to `custom-seatable-server.yml`.
30 | You should remove the `mariadb` service definition and update the `depends_on` declaration for the `seatable-server` service to ensure that it can start up.
31 |
32 | ```bash
33 | services:
34 | seatable-server:
35 | depends_on:
36 | mariadb: # < remove
37 | condition: service_healthy # < remove
38 |
39 | mariadb: # remove complete service
40 | ... # with all lines
41 | ```
42 |
43 | ## Update environment variables
44 |
45 | You should update/set the following environment variables in your `.env` file:
46 |
47 | ```ini
48 | MARIADB_HOST=
49 | MARIADB_PORT=
50 | MARIADB_PASSWORD=
51 | ```
52 |
53 | ## Restart SeaTable
54 |
55 | After that you can [restart SeaTable](../../maintenance/restart-seatable.md).
56 |
57 | ## Troubleshooting
58 |
59 | Check the logs and look for any connection errors.
60 |
61 | ```bash
62 | tail -f /opt/seatable-server/seatable/logs/*.log
63 | ```
64 |
65 | ## Remove old database
66 |
67 | if everything is running good, you can delete the local database folder /opt/mariadb.
68 |
69 | ```bash
70 | rm -r /opt/mariadb
71 | ```
72 |
--------------------------------------------------------------------------------
/manipulate-css.php:
--------------------------------------------------------------------------------
1 | ";
7 | exit(1);
8 | }
9 |
10 | $orange_codes = '/#(ff8000|ED7109|ed7109|ff6700|c60|bf6000|d96d00|20a0ff|E16C0A|feab79)/';
11 | $rgba_codes = '/(rgba\(255,128,0|rgba\(255,147,35|rgba\(255,147,38)/';
12 | $final_css = array();
13 | $placeholder = '##maincolor##';
14 |
15 | // Datei als Array eingelesen
16 | $array = explode("}", file_get_contents($argv[1]));
17 | $last = count($array)-1;
18 |
19 | foreach($array as $key => $value){
20 |
21 | $inside = "";
22 |
23 | // verschachtelte zusammenführen
24 | if ( substr_count($value, "{") > 1 ){
25 | $inside = "y";
26 | $inside_start = $key;
27 | $inside_ende = $key;
28 | }
29 | if ( trim($value) == "" AND $inside == "y" ){
30 | $inside_ende = $key;
31 | while($inside_start < $key){
32 | $array[$key] = trim($array[$key] ."\n". $array[$inside_start] ."}");
33 | unset($array[$inside_start]);
34 | $inside_start++;
35 | }
36 | $inside = "n";
37 | $value = $array[$key];
38 | }
39 |
40 | if( $inside != "y" ){
41 | $array[$key] = trim($value."}");
42 | }
43 | }
44 |
45 | // clean last element
46 | if ( trim($array[$last]) == "}" ) {
47 | unset($array[$last]);
48 | }
49 |
50 | // Array-Index wieder neu aufbauen
51 | $array = array_values($array);
52 |
53 | //print_r($array);
54 |
55 |
56 | // 1. save code-block only if it contains a "#..."
57 |
58 | foreach($array as $key => $value){
59 | if( preg_match($orange_codes, $value) OR preg_match($rgba_codes, $value) ){
60 |
61 | // 2. replace orange code with placehoder
62 | $tmp = str_replace(["\r", "\n"], '', preg_replace($rgba_codes, 'rgba(##mainrgba##', preg_replace($orange_codes, $placeholder, trim($value))));
63 | //$tmp = $tmp.'}';
64 |
65 | $final_css[] = $tmp;
66 | }
67 | }
68 |
69 | // implode array
70 | $final_css_string = implode("\n",$final_css);
71 |
72 | // jede Zeile durchgehen und alles entfernen, was kein . { } oder # enthält:
73 |
74 | $final_css_linebyline = explode("\n", $final_css_string);
75 | foreach($final_css_linebyline as $key => $value){
76 | if( !preg_match('/\.[a-zA-Z]|{|}|#/', $value) ){
77 | unset($final_css_linebyline[$key]);
78 | }
79 | }
80 | $final_css_linebyline = array_values($final_css_linebyline);
81 | $final_css_string2 = implode("\n",$final_css_linebyline);
82 |
83 | // Save to file
84 | file_put_contents($argv[1], $final_css_string2);
85 |
--------------------------------------------------------------------------------
/docs/configuration/authentication/oauth.md:
--------------------------------------------------------------------------------
1 | # OAuth
2 |
3 | First, register the Client App on the OAuth authorization server (such as [Github](https://github.com/settings/developers)), remember the Client ID and Client Secret, and set the Redirect Uri (Authorization callback URL in Github).
4 |
5 | Add the following configuration to dtable_web_settings.py:
6 |
7 | ```
8 | ENABLE_OAUTH = True
9 | OAUTH_ENABLE_INSECURE_TRANSPORT = True
10 | OAUTH_PROVIDER_DOMAIN = 'github.com'
11 | OAUTH_CLIENT_ID = "wd529b3b2ae8320e06fr"
12 | OAUTH_CLIENT_SECRET = "8159c3dcc8ef197cc3bbd94ff6cf101c93ba6d8r"
13 | OAUTH_REDIRECT_URL = 'https://test.seatable.cn/oauth/callback/'
14 | OAUTH_AUTHORIZATION_URL = 'https://github.com/login/oauth/authorize'
15 | OAUTH_TOKEN_URL = 'https://github.com/login/oauth/access_token'
16 | OAUTH_USER_INFO_URL = 'https://api.github.com/user'
17 | OAUTH_SCOPE = ["user",]
18 | OAUTH_ATTRIBUTE_MAP = {
19 | "id": "uid",
20 | "name": "name",
21 | "email": "contact_email",
22 | }
23 |
24 | ```
25 |
26 | The meaning of configuration option is as follows:
27 |
28 | #### **ENABLE_OAUTH_INSECURE_TRANSPORT**
29 |
30 | If https is not configured, you can add it in dtable_web_settings.py `ENABLE_OAUTH_INSECURE_TRANSPORT = True`。
31 |
32 | See more in
33 |
34 | **note:**
35 |
36 | If you use Google OAuth2 login, the OAUTH_SCOPE configuration should be configured as follows:
37 | ```
38 | OAUTH_SCOPE = ["openid", "https://www.googleapis.com/auth/userinfo.email", "https://www.googleapis.com/auth/userinfo.profile"]
39 | ```
40 |
41 |
42 | #### **OAUTH_PROVIDER**
43 |
44 | SeaTable uses this configuration to distinguish OAuth from other login methods,such as: github.com.
45 |
46 | #### **OAUTH_REDIRECT_URL**
47 |
48 | The Redirect URL, Authorization callback URL in Github, such as: https\://test.seatable.cn/oauth/callback/
49 |
50 | #### **OAUTH_AUTHORIZATION_URL、OAUTH_TOKEN_URL、OAUTH_USER_INFO_URL、OAUTH_SCOPE**
51 |
52 | Set these values according to the document of OAuth provider, for GitHub, please check [https://docs.github.com/en/developers/apps/authorizing-oauth-app](https://docs.github.com/en/developers/apps/authorizing-oauth-apps)
53 |
54 | #### **OAUTH_ATTRIBUTE_MAP**
55 |
56 | The correspondence between the user fields obtained from the OAuth authorization server and the user fields in SeaTable.
57 |
58 | * uid: the unique identifier for SeaTable identify a user from the OAuth provider.
59 | * name: the name of a user in SeaTable
60 | * contact_email: a user's contact email in SeaTable
61 |
--------------------------------------------------------------------------------
/docs/installation/advanced/ipv6-support.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Activate IPv6 Support for SeaTable
6 |
7 | SeaTable supports IPv6 in general. There is no special activation required.
8 |
9 | ## Docker and IPv6
10 |
11 | ### Problem
12 |
13 | There is one area that requires additional attention. Docker, by default, does not assign IPv6 addresses to its containers; instead, containers receive only IPv4 addresses.
14 |
15 | Requests arriving via an IPv6 connection still reach SeaTable. However, a problem arises for services like nginx or SeaTable that log the source IP address. Every incoming IPv6 request is logged with the Docker network gateway IP address (e.g., `172.18.0.1`), not the client’s actual IPv6 address. In the following screenshot, you can see that *Thierry* connected from an IPv6 address.
16 |
17 | 
18 |
19 | You can confirm this by running `docker inspect seatable-server`:
20 |
21 | ```json
22 | [
23 | {
24 | ...
25 | "Networks": {
26 | "frontend-net": {
27 | ...
28 | "Gateway": "172.18.0.1",
29 | "IPAddress": "172.18.0.5",
30 | "IPv6Gateway": "",
31 | "GlobalIPv6Address": "",
32 | ...
33 | }
34 | }
35 | }
36 | ]
37 | ```
38 |
39 | While this does not cause immediate service disruptions, it presents some challenges:
40 | - Incorrect client IPs are logged.
41 | - Rate limiting or other IP-based limits may behave incorrectly.
42 |
43 | ---
44 |
45 | ### Solution
46 |
47 |
48 |
49 | The solution is straightforward. Add the following parameter to your Docker network configuration (for example, in caddy.yml):
50 |
51 | ```
52 | networks:
53 | frontend-net:
54 | name: frontend-net
55 | enable_ipv6: ${ENABLE_IPV6:-true}
56 | ```
57 |
58 | This enables IPv6 addressing for the container and ensures accurate logging of client IP addresses. **Starting with SeaTable version 6.0**, this feature is enabled by default.
59 |
60 | ---
61 |
62 | ### Setups without IPv6
63 |
64 | !!! warning "What if IPv6 is completely diabled on your server?"
65 |
66 | If IPv6 is completely disabled, Docker may fail to start containers with errors such as:
67 |
68 | - `cannot read IPv6 setup`
69 | - `cannot assign requested address`
70 | - `failed to start container ... error="driver failed programming external connectivity`
71 | - `error response from daemon: attaching to network failed`
72 |
73 | In this case, set `ENABLE_IPV6=false` in your `.env` file to disable IPv6 support in Docker, allowing containers to start successfully.
--------------------------------------------------------------------------------
/docs/maintenance/domain-change.md:
--------------------------------------------------------------------------------
1 | # Changing Domain (URL)
2 |
3 | When changing the domain of your SeaTable Server, you must not only update configuration files but also ensure that all internal file and image URLs inside bases are updated. This section describes all necessary steps.
4 |
5 | ## 1. Update Configuration
6 |
7 | If your SeaTable Server’s URL changes (for example, from `https://old.example.com` to `https://new.example.com`), start by updating the following files:
8 |
9 | - **`/opt/seatable-compose/.env`** – Replace all instances of the old domain with the new one, especially `SEATABLE_SERVER_HOSTNAME`.
10 | - **`/opt/seatable-server/seatable/dtable_web_settings.py`** – Update variables containing the old domain, such as `DTABLE_WEB_SERVICE_URL`, `FILE_SERVER_ROOT` or any related configuration keys.
11 |
12 | After saving the changes, [restart all containers](./restart-seatable.md) to apply the new configuration.
13 |
14 | ## 2. Update SSL Certificates
15 |
16 | If you are using custom TLS/SSL certificates (not managed by Let’s Encrypt), you must [replace your existing certificate](../installation/advanced/custom-certificates.md) and key files to match the new domain. Make sure your new certificate is valid for the new domain before restarting the SeaTable services.
17 |
18 | ## 3. Transfer URLs Inside Bases
19 |
20 | Changing the domain cause images or files stored in bases to become unreadable. To fix existing links to these assets in file/image columns, SeaTable provides a management command that replaces all image and file URLs from the old domain with the new one.
21 |
22 | Open a shell inside the SeaTable container:
23 |
24 | ```
25 | docker exec -it seatable-server bash
26 | cd /opt/seatable/seatable-server-latest/dtable-web
27 | ```
28 |
29 | Run one of the following commands:
30 |
31 | ??? success "For all bases"
32 |
33 | ```
34 | seatable.sh python-env ./manage.py domain_transfer -all -od -nd
35 | ```
36 |
37 | To change the domain from `https://old.example.com` to `https://new.example.com`, run:
38 |
39 | ```
40 | seatable.sh python-env ./manage.py domain_transfer -all -od https://old.example.com -nd https://new.example.com
41 | ```
42 |
43 | ??? success "For a single base"
44 |
45 | ```
46 | seatable.sh python-env ./manage.py domain_transfer -uuid <:base uuid> -od -nd
47 | ```
48 |
49 | To change the domain for a base with UUID `695fa115-4927-4be1-b5b6-fbbbabd43b72` from `https://old.example.com` to `https://new.example.com`, run:
50 |
51 | ```
52 | seatable.sh python-env ./manage.py domain_transfer -uuid 695fa115-4927-4be1-b5b6-fbbbabd43b72 -od https://old.example.com -nd https://new.example.com
53 | ```
54 |
--------------------------------------------------------------------------------
/docs/installation/cluster/requirements.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Requirements
6 |
7 | The requirements for running a SeaTable cluster build upon those for a single-node setup. In addition to the standard prerequisites, the following requirements must be met to successfully deploy a cluster:
8 |
9 | - **At least 4 nodes** (physical or virtual) each with a minimum of 2 CPUs and 4 GB RAM.
10 | - All nodes are connected via a **private network**.
11 | - One node (running dtable-web) must be publically available via **port 80 and 443**.
12 | - **S3-compatible object storage** is required for storing files and attachments. (Alternative storage technologies may be possible but are not covered in detail here.)
13 | - **Centralized MariaDB and Redis services**: These must be accessible to all nodes in the private network. You can either use managed services or operate your own MariaDB and Redis instances.
14 | - If you plan to use the **Office Editor**, the service should be deployed within the private network.
15 | - You can deploy the **Python Pipeline** on the [same node as **dtable-web**](../components/python-pipeline.md) or on a [separate node](../advanced/python-pipeline-dedicated-server.md).
16 |
17 | !!! warning "Network communication is often the main challenge"
18 |
19 | In our experience, configuring communication between nodes and the overall network setup is the trickiest part of a cluster deployment.
20 | All nodes must be able to communicate with each other over a reliable, low-latency network connection.
21 | The performance of services such as MariaDB, Redis, and object storage is critical for stable cluster operation.
22 |
23 | If you can fulfill these requirements, you are ready to proceed with the [deployment of a SeaTable cluster](./basic-setup-with-external-services.md).
24 |
25 | ## Hardware recommendations for 1.000+ users
26 |
27 | Organizations frequently ask about the hardware resources needed to support more than 1,000 users. The following setup is recommended for companies or teams with 1,000 users, assuming average usage patterns, including some heavy users, API usage, Python scripting, and automations.
28 |
29 | This configuration is designed to handle typical workloads, but you should consider scaling resources further if you expect very large bases, intensive scripting, or high-frequency API calls, as these can significantly increase memory and CPU requirements.
30 |
31 | | Server component | CPUs | RAM (in GB) | Local storage (in GB) |
32 | | --- | --- | --- | --- |
33 | | dtable-web | 4 | 16 | 100 |
34 | | dtable-db | 4 | 16 | 100 |
35 | | dtable-server | 4 | 8 | 50 |
36 | | dtable-server-2 | 4 | 8 | 50 |
37 | | dtable-server-3 | 4 | 8 | 50 |
38 | | mariadb (self-hosted) | 4 | 16 | 100 |
39 | | python pipeline | 2 | 4 | 50 |
--------------------------------------------------------------------------------
/docs/configuration/authentication/saml-team.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | #search:
4 | # exclude: true
5 | ---
6 |
7 | # SAML Authentication (for multi-tenancy environments)
8 |
9 | The Team SAML feature allows each team in a multi-tenant SeaTable environment to configure its own SAML identity provider (IdP) for single sign-on. While the functionality is available in all deployments, configuration only makes sense in environments such as **cloud.seatable.io**, where multiple independent teams share the same infrastructure.
10 |
11 | ## Activation
12 |
13 | in `dtable_web_settings.py` add these settings:
14 |
15 | ```python
16 | # to activate teams in general
17 | CLOUD_MODE = True
18 | MULTI_TENANCY = True
19 |
20 | # to activate multi-saml in general
21 | ENABLE_MULTI_SAML = True
22 | SAML_CERTS_DIR = '/shared/certs'
23 | ```
24 |
25 | SAML for Teams is also a role permission that has to be assigned to a role.
26 |
27 | ```python
28 | ENABLED_ROLE_PERMISSIONS = {
29 | 'org_default': {
30 | 'can_use_saml': True
31 | },
32 | 'org_enterprise': {
33 | 'can_use_saml': True
34 | }
35 | }
36 | ```
37 |
38 | Server certificates have to be created in the host system and made available to SeaTable Server.
39 | The generated certificates are valid for 10 years.
40 |
41 | ```bash
42 | # executed in the host
43 | mkdir /opt/seatable-server/certs
44 | cd /opt/seatable-server/certs
45 | openssl req -x509 -nodes -days 3650 -newkey rsa:2048 -keyout sp.key -out sp.crt
46 | ```
47 |
48 | ## Property Mappings
49 |
50 | The IDP must provide the following SAML properties:
51 |
52 | - `contact_email`
53 | - `name`
54 | - `uid`
55 |
56 | The exact configuration depends on your specific IDP.
57 |
58 | ### Authentik
59 |
60 | Create three property mappings of type `SAML Provider Property Mapping` under `Customization -> Property Mappings` with the following settings:
61 |
62 | | Name | SAML Attribute Name | Expression |
63 | | ------------- | ------------------- | --------------------------- |
64 | | contact_email | `contact_email` | `return request.user.email` |
65 | | name | `name` | `return request.user.name` |
66 | | uid | `uid` | `return request.user.pk` |
67 |
68 | ```python
69 | #SAML_CERTS_DIR = '/opt/seatable/seatable-data'
70 | #SAML_ATTRIBUTE_MAP = {
71 | #'uid': 'uid',
72 | # 'contact_email': 'contact_email',
73 | # 'name': 'name',
74 | #}
75 | ```
76 |
77 | ## Cookie Settings
78 |
79 | If the SAML provider is on a separate domain (which it will definitely be in case of `cloud.seatable.io`), the following settings must be configured to prevent issues with cross-site cookies:
80 |
81 | ```python
82 | SESSION_COOKIE_SECURE = True
83 | SESSION_COOKIE_SAMESITE = 'None'
84 | CSRF_COOKIE_SECURE = True
85 | CSRF_COOKIE_SAMESITE = 'None'
86 | ```
87 |
--------------------------------------------------------------------------------
/docs/installation/components/ofelia.md:
--------------------------------------------------------------------------------
1 | # Ofelia
2 |
3 |
4 |
5 | [Ofelia](https://github.com/mcuadros/ofelia) is a job scheduler for Docker that allows you to run scheduled commands inside Docker containers.
6 | The commands and their respective schedules are specified through Docker labels.
7 |
8 | ## Installation
9 |
10 | ### Update the .env File
11 |
12 | To install Ofelia, add `ofelia.yml` to the `COMPOSE_FILE` variable in your `.env` file. This tells Docker to download the required Ofelia image.
13 |
14 | Simply copy and paste (:material-content-copy:) the following code into your command line to update your `.env` file:
15 |
16 | ```bash
17 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,ofelia.yml'/" /opt/seatable-compose/.env
18 | ```
19 |
20 | ### Start Ofelia
21 |
22 | Start Ofelia for the first time by running the following commands:
23 |
24 | ```bash
25 | cd /opt/seatable-compose && \
26 | docker compose up -d
27 | ```
28 |
29 | ### Logs
30 |
31 | You can use `docker logs -f ofelia` to view Ofelia's logs. By default, Ofelia forwards the output of all scheduled commands to its own `stdout` file descriptor.
32 |
33 | ## Configuration
34 |
35 | By default, `ofelia.yml` adds labels to the `seatable-server` service. These labels schedule three maintenance commands that run inside the `seatable-server` container:
36 |
37 | | Slug | Description | Schedule |
38 | | ----------- | ------------------------------------------------------------------------------------------------------------------------------- | --------- |
39 | | `clean-tmp` | Removes any files older than 3 days from the `/tmp` directory inside the container to the system from running out of disk space | `@weekly` |
40 | | `gc` | Runs the [garbage collection](../../maintenance/storage-cleanup.md) process to clean up unused blocks | `@weekly` |
41 | | `seaf-fsck` | Runs the [`seaf-fsck`](../../maintenance/filesystem-check.md) script to check the integrity of all Seafile libraries | `@weekly` |
42 |
43 | You are free to modify the schedule of these commands and/or add your own commands via additional labels on the `seatable-server` container.
44 | Please refer to [Ofelia's docs](https://github.com/mcuadros/ofelia/blob/master/README.md#configuration) for more details regarding the configuration format.
45 |
46 | !!! note "Configuration changes require a restart"
47 |
48 | Since Ofelia does not yet support the automatic reloading of label configuration, any changes to the Docker labels require a manual restart of Ofelia.
49 | You can achieve this by running the following command:
50 |
51 | ```bash
52 | # --force-recreate ensures that Ofelia is restarted
53 | docker compose up -d ofelia --force-recreate
54 | ```
55 |
--------------------------------------------------------------------------------
/docs/installation/advanced/settings-caddy.md:
--------------------------------------------------------------------------------
1 | # Advanced Settings for Caddy
2 |
3 | ## Enabling Logging for Caddy Docker Proxy
4 |
5 | To enable logging for the Lucas Lorentz Caddy Docker Proxy, you need to add a label to the **service container** (not the proxy container itself). For SeaTable Server, you can activate logging by adding the `caddy.log` label to your `seatable-server.yml` file.
6 |
7 | **Example Configuration**
8 |
9 | ```bash
10 | ---
11 | services:
12 | seatable-server:
13 | ...
14 | labels:
15 | caddy: ${SEATABLE_SERVER_PROTOCOL:-https}://${SEATABLE_SERVER_HOSTNAME:?Variable is not set or empty}
16 | # new: activate logs
17 | caddy.log:
18 | caddy.reverse_proxy: "{{upstreams 80}}"
19 | ...
20 | ```
21 |
22 | **Explanation**
23 |
24 | This label `caddy.log:` enables logging for the service and outputs logs to `stdout`. Once configured, you can view the logs using standard Docker commands, such as `docker logs ` or `docker compose logs seatable-server`.
25 |
26 | These logs are specific to the service container (e.g., SeaTable Server). To view logs for the Caddy proxy itself, check the logs of the Caddy proxy container.
27 |
28 | ## Preserve the Original Client IP Behind a Front Proxy
29 |
30 | If there is an additional reverse proxy (for example, a company-wide load balancer or a Cloudflare proxy) placed in front of your Caddy instance, you may notice that the SeaTable logs, web interface, or the underlying Nginx access logs only show the proxy’s IP address instead of the real client IP. This happens because Caddy treats the front proxy as the client and therefore forwards its IP instead of the external user's one.
31 |
32 | To fix this, you can configure Caddy to forward the original client’s IP address using the `X-Forwarded-For` header.
33 |
34 | **Example Configuration**
35 |
36 | ```bash
37 | ---
38 | services:
39 | seatable-server:
40 | ...
41 | labels:
42 | caddy: ${SEATABLE_SERVER_PROTOCOL:-https}://${SEATABLE_SERVER_HOSTNAME:?Variable is not set or empty}
43 | caddy.reverse_proxy: "{{upstreams 80}}"
44 | # new: forward external ip to seatable nginx
45 | caddy.reverse_proxy.header_up: "X-Forwarded-For {http.request.header.X-Forwarded-For}"
46 | ```
47 |
48 | **Explanation**
49 |
50 | The label `caddy.reverse_proxy.header_up: "X-Forwarded-For {http.request.header.X-Forwarded-For}"` instructs Caddy to copy the existing `X-Forwarded-For` header from the incoming HTTP request (added by the front proxy) and send it to the SeaTable Nginx container. As a result, SeaTable and its embedded Nginx will correctly log and display the original client IP address instead of the proxy’s IP.
51 |
52 | If there is no such header from the front proxy, Caddy will automatically generate one with the client’s own address. This ensures that IP forwarding works as expected in both single-proxy and multi-proxy setups.
--------------------------------------------------------------------------------
/docs/installation/advanced/custom-proxy.md:
--------------------------------------------------------------------------------
1 | # Replace caddy with another proxy
2 |
3 | The Single-Node Installation describes an installation of a SeaTable server with the webserver caddy. We dediced to use Caddy because it simplifies the handling of let's encrypt certificates.
4 | If you create a DNS entry and point it to your server, caddy will do everything else for you. Also we configured caddy with state of the art security configurations.
5 |
6 | ## Custom proxy with SeaTable Server
7 |
8 | But of cause there might be reasons when you want to replace caddy with another proxy like ha-proxy, traffik, nginx, apache etc. The logic of replacing might be simple.
9 |
10 | You can use any proxy as long as your forward all traffic to the SeaTable Server. Part of the SeaTable Server container is a nginx web proxy, which routes the traffic by URL. **This port 80 is not exposed therefore your proxy has to be in the same docker network like SeaTable Server**.
11 |
12 | 
13 |
14 | ## How to configure
15 |
16 | Remove `caddy.yml` from COMPOSE_FILE from .env file. Restart all docker containers. Forward all traffic to the SeaTable Container via port 80.
17 |
18 | !!! warning "SeaTable does not expose any ports"
19 |
20 | Please be aware that SeaTable does not expose port 80 to the outside. Therefore your proxy has to be in the same docker network. Otherwise you have to expose port 80 of SeaTable Server.
21 |
22 | ## Custom proxy with additional components
23 |
24 | For the additional components you can choose between two different options. You can access the services either via separate port or (sub)domain.
25 |
26 | ### Option 1: use ports to access the services
27 |
28 | The additional components run on separate ports. n8n uses the port 6231. If you only have one public domain available, you can forward the required port to the internal network and access the service. This does not require any further configuration.
29 |
30 | 
31 |
32 | ### Option 2: other domains to access the services
33 |
34 | In this case, you use another (sub)domain to access the service. You create a proxy rule to route the traffic to the service with its internal port. Usually this requires that you also change the configuration of the service to be accessable via this additonal domain.
35 |
36 | 
37 |
38 | ## Proxy outside of the docker network
39 |
40 | To use a proxy outside of your Docker network, you’ll need to expose port 80 on your SeaTable server and route all traffic through it. Alternatively, you can expose a different port and forward it to the internal port 80 on Nginx.
41 |
42 | Because network configurations vary widely, it’s difficult to provide specific instructions for every setup. This approach requires familiarity with networking and routing concepts.
43 |
--------------------------------------------------------------------------------
/docs/installation/advanced/seatable-ai-standalone.md:
--------------------------------------------------------------------------------
1 | # Standalone Deployment of SeaTable AI
2 |
3 | This guide describes the standalone deployment of `seatable-ai` on a dedicated server or virtual machine.
4 |
5 | ## Prerequisites
6 |
7 | - You have successfully installed [Docker and Docker-Compose](../basic-setup.md#install-docker-and-docker-compose-plugin)
8 | - You have [downloaded the latest `.yml` files](../basic-setup.md#1-create-basic-structure) from the `seatable-release` GitHub repository
9 | - The hosts destined to run `seatable-ai` and other SeaTable components are attached to the same private network
10 |
11 | ## SeaTable AI Configuration
12 |
13 | The following section outlines an `.env` file with the settings needed to run `seatable-ai`.
14 | These changes should be made inside `/opt/seatable-compose/.env`:
15 |
16 | ```ini
17 | COMPOSE_FILE='seatable-ai-standalone.yml'
18 | COMPOSE_PATH_SEPARATOR=','
19 |
20 | # system settings
21 | TIME_ZONE='Europe/Berlin'
22 |
23 | # database
24 | MARIADB_HOST=
25 | MARIADB_PORT=3306
26 | MARIADB_PASSWORD=
27 |
28 | # redis
29 | REDIS_HOST=
30 | REDIS_PORT=6379
31 | REDIS_PASSWORD=
32 |
33 | # This private key must have the same value as the JWT_PRIVATE_KEY variable on other SeaTable nodes
34 | JWT_PRIVATE_KEY=
35 |
36 | # Public URL of your SeaTable server
37 | SEATABLE_SERVER_URL=https://seatable.your-domain.com
38 |
39 | # Cluster-internal URL of dtable-server
40 | INNER_DTABLE_SERVER_URL=http://dtable-server:5000
41 |
42 | # Cluster-internal URL of dtable-db
43 | INNER_DTABLE_DB_URL=http://dtable-db:7777
44 |
45 | # LLM
46 | SEATABLE_AI_LLM_TYPE=
47 | SEATABLE_AI_LLM_URL=
48 | SEATABLE_AI_LLM_KEY=
49 | SEATABLE_AI_LLM_MODEL=
50 | ```
51 |
52 | !!! warning "Ports are not exposed by default"
53 |
54 | By default, the ports of `dtable-server` (5000) and `dtable-db` (7777) are not exposed to the host. This requires a manual change inside the `.yml` file.
55 |
56 | ### LLM Provider Configuration
57 |
58 | Please refer to the documentation on [configuring your LLM provider of choice](../components/seatable-ai.md#llm-provider-configuration).
59 | These configuration details do not change depending on the deployment topology of `seatable-server` and `seatable-ai`.
60 |
61 | ### Start SeaTable AI
62 |
63 | You can now start SeaTable AI by running the following command inside your terminal:
64 |
65 | ```bash
66 | cd /opt/seatable-compose
67 | docker compose up -d
68 | ```
69 |
70 | ## Configuration of SeaTable Server
71 |
72 | Since `seatable-ai` is now running on a separate host or virtual machine, the following configuration changes must be made inside the `.env` file on the host running the `seatable-server` container:
73 |
74 | ```ini
75 | ENABLE_SEATABLE_AI=true
76 | SEATABLE_AI_SERVER_URL='http://seatable-ai.example.com:8888'
77 | ```
78 |
79 | Restart the `seatable-server` service and test your SeaTable AI:
80 |
81 | ```bash
82 | cd /opt/seatable-compose
83 | docker compose up -d
84 | ```
85 |
--------------------------------------------------------------------------------
/docs/installation/components/clamav.md:
--------------------------------------------------------------------------------
1 | # Deploy ClamAV with SeaTable
2 |
3 |
4 |
5 |
6 | SeaTable supports antivirus scanning using ClamAV. It automatically scans newly uploaded or updated assets (such as images and files) for viruses.
7 |
8 | ## Installation
9 |
10 | ### Update the .env File
11 |
12 | To install ClamAV, add `clamav.yml` to the `COMPOSE_FILE` variable in your `.env` file. This tells Docker to download and configure the required ClamAV image.
13 |
14 | Simply copy and paste (:material-content-copy:) the following code into your command line to update your `.env` file:
15 |
16 | ```bash
17 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,clamav.yml'/" /opt/seatable-compose/.env
18 | ```
19 |
20 | ### Configure `dtable-events.conf`
21 |
22 | Add the following configuration to the `dtable-events.conf` file to enable virus scanning:
23 |
24 | ```conf
25 | [VIRUS SCAN]
26 | enabled = true
27 | scan_command = clamdscan
28 | scan_interval = 60
29 | virus_code = 1
30 | nonvirus_code = 0
31 | ```
32 |
33 | ### Start ClamAV
34 |
35 | Start ClamAV for the first time by running:
36 |
37 | ```bash
38 | cd /opt/seatable-compose && \
39 | docker compose up -d
40 | ```
41 |
42 | Once started, you should see an entry like this in your `dtable-events.log`:
43 |
44 | ```log
45 | [INFO] virus_scanner.py[line:21] Start virus scanner, interval = 3600 sec
46 | ```
47 |
48 | ClamAV will now continuously scan images and files attached to your bases for viruses.
49 |
50 | ## Usage
51 |
52 | After enabling ClamAV, a new section will appear in the admin area where you can view detected viruses. For each finding, you’ll see:
53 |
54 | - The base where the infected file is located.
55 | - The file name.
56 | - The current status of the detection.
57 |
58 | You can choose to either ignore the finding or delete the infected asset.
59 |
60 | 
61 |
62 | ## Advanced Topics
63 |
64 | ### Additional Configuration Options
65 |
66 | ClamAV offers advanced configuration options in dtable-events.conf, such as:
67 |
68 | - **Scan interval**: Adjust how often scans are performed.
69 | - **File size limit**: Set a maximum size for scanned files.
70 | - **Ignored file extensions**: Specify file types to exclude from scanning.
71 | - **Thread count**: Define how many threads are used for scanning.
72 |
73 | For more details, refer to the [dtable-events configuration documentation](../../configuration/dtable-events-conf.md).
74 |
75 | ## Updating Virus Signature Files
76 |
77 | The ClamAV Docker container uses Freshclam to update its virus signature database automatically every three hours. While this keeps ClamAV up-to-date, its detection capabilities may not be as robust as those of other paid antivirus solutions.
78 |
79 | ## E-Mail notification
80 |
81 | Email notifications for virus detection will be available in a future update.
82 |
83 |
84 |
85 |
86 |
--------------------------------------------------------------------------------
/docs/configuration/authentication/jwt.md:
--------------------------------------------------------------------------------
1 | # JSON Web Tokens
2 |
3 | JSON Web Tokens (=JWT) is another authentication type SeaTable provides. It is used by the SeaTable API but it can also be used to allow server-to-server authentication. JWTs are used for example if you switch from (SeaTable Cloud)[https://cloud.seatable.io] to the (team administration)[https://account.seatable.io] without the need to re-authenticate.
4 |
5 | ## What is JWT?
6 |
7 | JWT is a very popular technology but comes with its share of controversy. Some say you should never use it. Others say JWT authentication is amazing. We think that JWT can be very helpful in some specific scenarios.
8 | If you want to know more aboout JWT, please read [this article](https://blog.logrocket.com/jwt-authentication-best-practices/).
9 |
10 | Here is a short introduction into JWT:
11 |
12 | - JWT is an encoded and cryptographically signed URL, that contains an json object.
13 | - This json object can contain any kind and amount of data.
14 | - When a server receives this JWT it can guarantee the data it contains can be trusted because it's signed (not encrypted).
15 | - Both parties (sender and receiver) must know a shared secret that is used to sign the JWT request.
16 |
17 | ## How to configure and use JWT?
18 |
19 | To enable the login with JWTs you have to define a secret key in your `dtable_web_settings.py` and restart the SeaTable service:
20 | ```
21 | SSO_SECRET_KEY = 'your-shared-secret-like-a38B232XQJLx392871#2DEF_dowfWE#_39dwefidWFwLw39fDFEF='
22 | ```
23 |
24 | Afterwards SeaTable allows the login with the following URL `https://cloud.seatable.io/sso-auto-login/?token=...`.
25 |
26 | The token is the encoded json object with these elements:
27 |
28 | ```json
29 | {
30 | "exp": "1682582542",
31 | "user_id": "b7bd00e840a14b748ce2bffdf409488b@auth.local"
32 | }
33 | ```
34 |
35 | ## Examples how to use JWT and generate the login-link
36 |
37 | Every programming language offers libraries to sign JWTs. A good place to start looking for such a library is (https://jwt.io/libraries)[https://jwt.io/libraries].
38 |
39 | Here is an example with PHP and the (firebase-library)[https://github.com/firebase/php-jwt]:
40 |
41 | ```php
42 | // This code generates an URL to login as the user defined in user_id.
43 | // The URL is valid for 30 seconds.
44 | // After successful login, the user jumps to $url_next.
45 |
46 | $url_next = "/"
47 | $jwt_signing_key = "your-shared-secret"
48 | $payload = [
49 | "exp" => time() + 30,
50 | "user_id" => "b7bd00e840a14b748ce2bffdf409488b@auth.local",
51 | ];
52 | $jwt = \Firebase\JWT\JWT::encode($payload, $jwt_signing_key, 'HS256');
53 | $jwt_url = 'https://cloud.seatable.io/sso-auto-login/?token='. rawurlencode($jwt) . $url_next;
54 | echo $jwt_url;
55 | ```
56 |
57 | Other examples can be found here:
58 |
59 | - [Vue and Node.js](https://blog.logrocket.com/how-to-implement-jwt-authentication-vue-nodejs/)
60 | - [Python](https://medium.com/@apcelent/json-web-token-tutorial-with-example-in-python-df7dda73b579)
--------------------------------------------------------------------------------
/docs/installation/components/releem.md:
--------------------------------------------------------------------------------
1 | # Releem
2 |
3 | **Releem** is a MySQL performance monitoring and tuning tool designed to optimize your MariaDB database. It operates alongside your database, collecting performance data and providing recommended configuration improvements. While Releem offers automated insights, experienced database professionals may prefer manual tuning for deeper control.
4 |
5 | 
6 |
7 | ## Register for a releem account
8 |
9 | - Visit the [Releem website](https://releem.com/) and sign up for a new account.
10 | - After registration, obtain your **RELEEM_API_KEY**.
11 |
12 | ## Create a dedicated database user
13 |
14 | Releem requires its own user in your MariaDB instance. Log in to your MariaDB server and execute the following commands, replacing `[RELEEM_DB_USER_PASSWORD]` with a secure password:
15 |
16 | ```sql
17 | CREATE USER 'releem'@'%' identified by '[RELEEM_DB_USER_PASSWORD]';
18 | GRANT PROCESS, REPLICATION CLIENT, SHOW VIEW ON *.* TO 'releem'@'%';
19 | GRANT SELECT ON performance_schema.events_statements_summary_by_digest TO 'releem'@'%';
20 | GRANT SELECT ON performance_schema.table_io_waits_summary_by_index_usage TO 'releem'@'%';
21 | ```
22 |
23 | ## Configure Releem in your environment
24 |
25 | Add `releem.yml` to the `COMPOSE_FILE` variable in your `.env` file and set the following environment variables:
26 |
27 | - **RELEEM_HOSTNAME**: A unique identifier for your server (useful if monitoring multiple systems).
28 | - **RELEEM_DB_USER_PASSWORD**: The password you set above.
29 | - **RELEEM_API_KEY**: Your API key from Releem.
30 |
31 | ## Data collection and optimization
32 |
33 | After starting the Releem agent, it will begin collecting performance metrics from your MariaDB database. Within 24 hours, Releem will provide optimized configuration recommendations based on your database workload.
34 |
35 | ## Apply optimized MariaDB settings
36 |
37 | 1. **Create a Custom Configuration File**
38 |
39 | Create a file named `99-mariadb-custom.cnf` with your optimized settings that Releem recommended to you.
40 |
41 | **This is just an example:**
42 |
43 | ```ini
44 | [mariadb]
45 | query_cache_limit = 1M
46 | query_cache_size = 128M
47 | expire_logs_days = 10
48 | innodb_buffer_pool_size = 1946157056
49 | ```
50 |
51 | 2. **Mount the Configuration File in Your Docker Compose Setup**
52 |
53 | Add the following volume to your `docker-compose.yml` for the MariaDB service:
54 |
55 | ```
56 | ---
57 | services:
58 | mariadb:
59 | ...
60 | volumes:
61 | - "/opt/mariadb:/var/lib/mysql"
62 | - "./99-mariadb-custom.cnf:/etc/mysql/conf.d/99-mariadb-custom.cnf"
63 | ```
64 |
65 | 3. **Restart MariaDB**
66 |
67 | Restart your MariaDB container to apply the new settings.
68 |
69 | After the restart, your database will use the new configuration. Releem will continue to monitor and suggest further optimizations as needed.
70 |
--------------------------------------------------------------------------------
/docs/installation/advanced/python-pipeline-dedicated-server.md:
--------------------------------------------------------------------------------
1 | # Python Pipeline on a separate server
2 |
3 | If your user base on your Seatable Server is growing, one of the first components that you could move to a separate server is the python pipeline. This frees up ressoures for the main server and it increases the security because customer python code is not executed on the main server.
4 |
5 | ## Requirements
6 |
7 | To install Python Pipeline on a separate server, use at least these ressources:
8 |
9 | - 2 CPU
10 | - 4 GB RAM
11 | - 40 GB SSD
12 |
13 | Use a separate domain or subdomain that is public available or you need a valid wildcard certificate.
14 | Caddy will generate a let's encrypt certificate.
15 |
16 | !!! warning "No self signed certificates"
17 |
18 | Self signed certificates are not recommended. Read the article about [custom certificates](./custom-certificates.md) for more details.
19 |
20 | !!! warning "Configure a firewall"
21 |
22 | Please configure a firewall to only allow access to port 80 and 443.
23 | These ports are required in order to receive a certificate from Let's Encrypt.
24 |
25 | The value of the variable `SEATABLE_SERVER_PUBLIC_IP` is used by Caddy to restrict access to the `python-scheduler` on layer 7.
26 | Only the virtual machine running `dtable-web` should be allowed to access the python-scheduler component.
27 |
28 | The Python pipeline should **not** be deployed on a virtual machine that is attached to a private network since the script containers can
29 | access this network interface if you do not configure any additional firewall rules.
30 |
31 | ## Deployment of the Python Pipeline
32 |
33 | The deployment of a separate python pipeline is simple. Get seatable-release from github like described in the installation of seatable server and only use `caddy.yml` and `python-pipeline-standalone.yml`.
34 |
35 | Update your `.env`, that it looks like this and add/update the values according to your needs:
36 |
37 | ```
38 | COMPOSE_FILE='caddy.yml,python-pipeline-standalone.yml'
39 | COMPOSE_PATH_SEPARATOR=','
40 |
41 | # system settings
42 | TIME_ZONE='Europe/Berlin'
43 |
44 | # seatable server url
45 | SEATABLE_SERVER_HOSTNAME=seatable.your-url.com
46 |
47 | # database
48 | MARIADB_PASSWORD=your-password
49 |
50 | # python-pipeline-standalone
51 | PYTHON_SCHEDULER_HOSTNAME=python.your-url.com
52 | PYTHON_SCHEDULER_AUTH_TOKEN=shared secret with dtable_web_settings.py
53 | # Only this IP is allowed to access the python-scheduler
54 | SEATABLE_SERVER_PUBLIC_IP='IP of seatable.your-url.com'
55 | ```
56 |
57 | Execute `docker compose up -d` to fire up your separate python pipeline.
58 |
59 | ## Configuration of SeaTable Server
60 |
61 | SeaTable must know how to access the Python Pipeline.
62 |
63 | Update the `.env` on the seatable server and add these two informations:
64 |
65 | ```bash
66 | PYTHON_SCHEDULER_URL=https://python.your-url.com
67 | PYTHON_SCHEDULER_AUTH_TOKEN=shared secret with python scheduler
68 | ```
69 |
70 | Restart seatable service and test your python pipeline.
71 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## Seatable Admin Docs Repository
2 |
3 | Welcome to the SeaTable Admin Docs Repository! 🌊🔍✨
4 |
5 | This repository serves as the foundational source for the SeaTable Admin Manual available at https://admin.seatable.com. The admin manual is generated with the help of MkDocs Material and is a comprehensive guide and resource hub for administrators to install, configure and maintain their own SeaTable Server.
6 |
7 | This repository contains the SeaTable Admin documentation. The documentation is built using , a fast and simple static site generator. The pages are being built using Github workflows and hosted on Github Pages.
8 |
9 | ## Content of the Admin Docs
10 |
11 | - Installation
12 | - Configuration
13 | - Technical Descriptions
14 | - Maintenance like Backup, Restore and Cleanup
15 |
16 | ## How to participate
17 |
18 | Please fell free to particiate in the admin manual by creating pull requests. Before you do this, please test your changes in a local copy of this manual. Here is how you can do this.
19 |
20 | > :warning: Docker is required
21 | >
22 | > We use Docker to create this local admin manual copy. You have to install docker first, if you don't have it already on your local machine. Use this one line command to easily install it on a linux machine:
23 | >
24 | > `curl -fsSL get.docker.com | bash`
25 |
26 | ### Step 1: Clone this repository and checkout a new branch
27 |
28 | ```bash
29 | git clone https://github.com/seatable/seatable-admin-docs
30 | cd seatable-admin-docs
31 | git checkout -b
32 | # please replace with something short like "fix_typo_saml_auth"
33 | ```
34 |
35 | ### Step 2: Generate your local version of the admin manual
36 |
37 | We developed a tiny bash script to generate the local copy of the admin manual.
38 |
39 | ```bash
40 | ./preview.sh
41 | ```
42 |
43 | Initiate your browser and access http://127.0.0.1:8000 to view a local copy of the manual. Any modifications made locally will be instantly reflected in this version. You don't even have to restart docker or reload the page.
44 |
45 | The manual can be found within the `docs` folder. For comprehensive guidance on utilizing [MKDocs](https://www.mkdocs.org/user-guide/) or [MkDocs Material](https://squidfunk.github.io/mkdocs-material/), refer to their respective manuals for detailed instructions.
46 |
47 | ### Step 3: Create a pull request
48 |
49 | The last step is to create a pull request will your proposed changes.
50 |
51 | ```bash
52 | git add .
53 | git commit -m ""
54 | git push
55 | ```
56 |
57 | ### Step 4: Stop the docker container with your local admin manual copy
58 |
59 | ```bash
60 | ./preview.sh -stop
61 | ```
62 |
63 | ## Feedback and Support
64 |
65 | Feel free to raise issues or reach out with any questions, feedback, or suggestions. We're here to support your SeaTable admin endeavors! We welcome contributions and feedback from the SeaTable community.
66 |
67 | Another source of information is the [SeaTable community forum](https://forum.seatable.com). A lot of questions regarding the installation, configuration and maintenance was already raised and answered there.
68 |
--------------------------------------------------------------------------------
/docs/installation/components/whiteboard.md:
--------------------------------------------------------------------------------
1 | # Whiteboard (tldraw)
2 |
3 |
4 |
5 |
6 | SeaTable's whiteboard plugin offers a versatile platform for capturing thoughts and data, independent of base data. This plugin utilizes the [tldraw SDK](https://tldraw.dev) and requires special installation steps, including server-side components for collaborative drawing.
7 |
8 | 
9 |
10 | ## Installation Requirements
11 |
12 | 1. SeaTable Enterprise Edition installed and running
13 | 2. Firewall configured to allow traffic on port 6239
14 | 3. System admin to install both the whiteboard plugin and the tldraw worker (server component)
15 |
16 | ## tldraw-worker Installation
17 |
18 | Follow these steps to deploy the tldraw worker on the same node as the seatable-server:
19 |
20 | #### Update .env file
21 |
22 | Like with all additional components you need to add `tldraw.yml` to the `COMPOSE_FILE` variable in your `.env` file.
23 |
24 | Simply copy and paste (:material-content-copy:) the following code into your command line:
25 |
26 | ```bash
27 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,tldraw.yml'/" /opt/seatable-compose/.env
28 | ```
29 |
30 | #### Launch the worker
31 |
32 | Start the `tldraw-worker`:
33 |
34 | ```bash
35 | cd /opt/seatable-compose && \
36 | docker compose up -d
37 | ```
38 |
39 | #### Verify Installation
40 |
41 | After a few seconds, check `https://:6239/ping`. You should see:
42 |
43 | ```
44 | {"status":"pong"}
45 | ```
46 |
47 | This confirms that the `tldraw-worker` is operational. If you don't see this message, check that port 6239 is allowed and the container logs.
48 |
49 | ## Final Steps
50 |
51 | With the server-side installation complete, you can now install the **whiteboard plugin** through the SeaTable admin interface and begin using this creative tool.
52 |
53 | ---
54 |
55 | ## Advanced Configuration
56 |
57 | ### Custom Certificate
58 |
59 | You need to make some changes to your `tldraw-worker` deployment in case your SeaTable server uses an internal CA.
60 | It is not recommended to make changes to the provided `tldraw.yml` file.
61 | You should copy `tldraw.yml` to `custom-tldraw.yml` and reference this file in your `.env` file instead.
62 |
63 | The following changes need to be made in order to use an internal CA:
64 |
65 | ```yaml
66 | services:
67 | tldraw-worker:
68 | # ...
69 | environment:
70 | # ...
71 | # Configure Extra CA (chain) for node.js
72 | - NODE_EXTRA_CA_CERTS=/usr/local/share/ca-certificates/MY-CA.pem
73 | volumes:
74 | # Mount the CA file into the container
75 | - ./MY-CA.pem:/usr/local/share/ca-certificates/MY-CA.pem:ro
76 | ```
77 |
78 | ### Subfolder Installation
79 |
80 | Deploying the tldraw-worker using a subfolder (e.g. `/tldraw`) instead of port 6239 is **not yet supported**.
81 |
82 | You can refer to the following forum post for details regarding the required changes in your reverse proxy and the whiteboard plugin itself: [forum.seatable.com/t/configuring-new-whiteboard-plugin-tldraw/6482](https://forum.seatable.com/t/configuring-new-whiteboard-plugin-tldraw/6482)
83 |
--------------------------------------------------------------------------------
/docs/installation/components/dozzle.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Dozzle
6 |
7 |
8 |
9 |
10 | [Dozzle](https://dozzle.dev/) is a lightweight, open-source web-based log viewer for Docker containers. It provides real-time monitoring of container logs without storing data persistently, making it ideal for quick debugging in containerized environments like SeaTable. Key features include fuzzy and regex search, SQL-based log queries, split-screen views for multiple containers, live CPU/memory stats, and multi-user authentication.
11 |
12 | A dedicated sidecar container (`seatable-logs` based on `sumologic/tailing-sidecar`) tails SeaTable log files from `/opt/seatable-server/seatable/logs` and redirects them to stdout, enabling seamless aggregation by **Dozzle** via the Docker socket.
13 |
14 | In a SeaTable context, it simplifies troubleshooting by aggregating logs from all services in your Docker Compose stack via the shared Docker socket.
15 |
16 | {style="border-radius:12px; padding:16px; background-color:#f5f5f5"}
17 |
18 | !!! warning "Logs may contain sensitive data"
19 |
20 | Dozzle logs may expose sensitive information like passwords, API keys, base URLs or personal data. Restrict access to authorized users only and avoid public exposure.
21 |
22 | ## Installation
23 |
24 | This guide explains how to install **Dozzle** on your SeaTable server.
25 |
26 | ### Change the .env file
27 |
28 | As with other additional components, first add `dozzle.yml` to the `COMPOSE_FILE` variable in your `.env` file.
29 |
30 | Copy and paste (:material-content-copy:) the following command into your terminal:
31 |
32 | ```bash
33 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,dozzle.yml'/" /opt/seatable-compose/.env
34 | ```
35 |
36 | ### Create a dozzle admin login
37 |
38 | Dozzle requires you to create login credentials. Use the command line tool `pwgen` to create a secure password for your *dozzle admin account*.
39 |
40 | The following command will generate the necessary file at `/opt/dozzle/users.yaml`:
41 |
42 | ```bash
43 | export DOZZLE_PASSWORD=`pwgen -c 40 1`
44 | docker run -it --rm amir20/dozzle generate --name DozzleAdmin --email dozzleadmin@example.com --password ${DOZZLE_PASSWORD} dozzleadmin > /opt/dozzle/users.yaml
45 | echo 'Now you can login to dozzle with `dozzleadmin` + `'${DOZZLE_PASSWORD}'`'
46 | ```
47 |
48 | Alternatively, you can change the command and adapt it to your needs.
49 |
50 | !!! danger "Avoid special characters in passwords"
51 |
52 | When setting passwords manually (without `pwgen`), do **not** use special characters such as `%`, `#`, `$`, `&`, `'`, `"` or similar. These may cause issues and can prevent that you can login to Dozzle.
53 |
54 | Instead, choose a **long password** using uppercase, lowercase, and digits to ensure both compatibility and security.
55 |
56 | ### Start Dozzle
57 |
58 | To start **Dozzle** for the first time, run:
59 |
60 | ```
61 | cd /opt/seatable-compose && \
62 | docker compose up -d
63 | ```
64 |
65 | ## Next steps
66 |
67 | After startup, **Dozzle** is accessible at `https://:6241`.
68 |
--------------------------------------------------------------------------------
/docs/introduction/security.md:
--------------------------------------------------------------------------------
1 | # Security measures
2 |
3 | Security is more than just activating a function or implementing a web-application firewall. Security is an ongoing process with a holistic view on all relevant topics. We try to define sinnvolle default values implementing best practies to improve the security without creating to many restrictions that might produce problems with some older clients.
4 |
5 | ## Web-Security
6 |
7 | Due to the fact that SeaTable is a mainly used via the browser, we took quiet some effort to implement good security measures. HTTPS is mandatory by default, modern ciphers are required and we enforce some security headers to prevent against typical script kiddies attacks.
8 |
9 | This configuration approach delivers good results, that are confirmed by known security experts in the internet:
10 |
11 | - A+ from [https://www.ssllabs.com/](https://www.ssllabs.com/ssltest/analyze.html?d=cloud.seatable.io)
12 | - A from [https://securityheaders.com/](https://securityheaders.com/?q=https%3A%2F%2Fcloud.seatable.io)
13 | - 100% from [internet.nl](https://internet.nl/site/cloud.seatable.io/)
14 | - 80/100 or B+ from [https://observatory.mozilla.org/](https://observatory.mozilla.org/analyze/cloud.seatable.io)
15 |
16 | ## Network security
17 |
18 | SeaTable's architecture encompasses a constellation of services and containers, each fortified with robust security measures. Our approach emphasizes the publication of only a singular service to the internet, strategically limiting the attack surface.
19 |
20 | Complementing this, network segmentation is rigorously enforced, ensuring containers are cordoned off from one another and allowing only vital communication within the ecosystem. In meticulous detail, we've established distinct networks: one tailored for containers necessitating public accessibility and another reserved for internal, non-public traffic.
21 |
22 | This meticulous design ensures a fortified defense posture, shielding SeaTable's infrastructure from potential threats while safeguarding the integrity of its operations.
23 |
24 | ## Security scans and vulnerabilities
25 |
26 | Ensuring security in CI deployment is paramount for us. This entails maintaining strict control over our deployment pipeline, implementing rigorous linting and code formatting checks, and conducting automatic testing with CVE vulnerability scanners. These measures collectively contribute to the generation of up-to-date container images, safeguarding our infrastructure against potential vulnerabilities.
27 |
28 | ## Documentation, Support and source code
29 |
30 | While it's true that any software product can simply be run, that approach doesn't align with our philosophy. Our mission is to create the world's leading self-hosted no-code database and app building platform. In pursuit of this goal, we prioritize several key components:
31 |
32 | - Comprehensive documentation to empower users at every step.
33 | - A responsive and knowledgeable support team to swiftly address any inquiries or issues.
34 | - Availability of the source code, with exceptions made only to protect our intellectual property.
35 |
36 | By adhering to these principles, we aim to provide a seamless and empowering experience for our users, fostering innovation and creativity in their projects.
37 |
--------------------------------------------------------------------------------
/docs/installation/advanced/python-pipeline-custom-python-runner.md:
--------------------------------------------------------------------------------
1 | # Create your own SeaTable Python Runner
2 |
3 | The SeaTable Python Pipeline includes a pre-configured python-runner image with numerous third-party Python libraries to execute your scripts. For a complete list of the included libraries, refer to the [Developer Manual](https://developer.seatable.com/scripts/python/common_questions/#install-and-use-custom-python-libraries).
4 |
5 | If you require additional Python packages, you can either contact support to request their inclusion in future versions or build your own custom image by extending the existing one.
6 |
7 | ## Build your own custom python runner image
8 |
9 | This guide assumes you will create the custom Python runner image directly on your server. If you choose to build it locally, you must push the custom image to an image registry (e.g., Docker Hub), which is outside the scope of this guide.
10 |
11 | ### Step 1: Create a `Dockerfile`:
12 |
13 | Create a `Dockerfile` with the following content:
14 |
15 | ```Dockerfile
16 | # You can find the latest tag here: https://hub.docker.com/r/seatable/seatable-python-runner/tags
17 | # or simply use the "latest" tag.
18 | FROM seatable/seatable-python-runner:latest
19 |
20 | # Install your custom-packages with pip
21 | RUN pip install --user --no-cache-dir \
22 | pypdf \
23 | pytesseract \
24 | # Replace with your required packages
25 | ```
26 |
27 | ### Step 2: Build your Image
28 |
29 | Run the following command to build your image. Use the `-t` option to specify a custom name and tag:
30 |
31 | ```bash
32 | docker build . -t custom-python-runner:1.0
33 | ```
34 |
35 | ### Step 3: Configure SeaTable to Use Your Custom Image
36 |
37 | Update your `/opt/seatable-compose/.env` file to specify your custom Python runner image:
38 |
39 | ```ini
40 | PYTHON_RUNNER_IMAGE='custom-python-runner:1.0'
41 | ```
42 |
43 | After updating the .env file, restart your SeaTable setup with:
44 |
45 | ```
46 | docker compose up -d
47 | ```
48 |
49 | You can verify that your custom image is being used by running:
50 |
51 | ```
52 | docker ps
53 | ```
54 |
55 | ### Step 4: Verify Installed Packages
56 |
57 | Run this Python script within SeaTable to confirm that your required packages are available:
58 |
59 | ```
60 | import importlib.metadata
61 |
62 | distributions = importlib.metadata.distributions()
63 | installed_packages = [dist.metadata['Name'] for dist in distributions]
64 | print(installed_packages)
65 | ```
66 |
67 | This script will display a list of installed Python packages.
68 |
69 | 
70 |
71 | ## Important Considerations
72 |
73 | !!! warning "No Automatic Updates"
74 |
75 | By creating a custom Python runner image, you forgo automatic updates. When a new base image version is released, manually rebuild your custom image to incorporate the latest changes.
76 |
77 | !!! warning "Footprint"
78 |
79 | While installing additional Python packages won't significantly slow down your Python Docker Runner, it will:
80 |
81 | - Increase the container's size
82 | - Potentially increase memory usage
83 |
84 | These factors may affect deployment time and resource allocation, but usually won't impact runtime performance noticeably.
--------------------------------------------------------------------------------
/docs/maintenance/storage-cleanup.md:
--------------------------------------------------------------------------------
1 | # Storage Cleanup (Garbage Collection)
2 |
3 | SeaTable uses storage de-duplication technology to reduce storage usage. The underlying data blocks will not be removed immediately after you delete a file or a base. As a result, the number of unused data blocks will increase on SeaTable server.
4 |
5 | To release the storage space occupied by unused blocks, you have to run a **garbage collection** program to clean up unused blocks on your server.
6 |
7 | !!! note "Use Ofelia to enable scheduled garbage collection"
8 |
9 | You can add [Ofelia](../installation/components/ofelia.md) to your SeaTable deployment to run the garbage collection process on a [configurable interval](../installation/components/ofelia.md#configuration).
10 | This ensures that any unused data blocks will be automatically cleaned up.
11 |
12 | ## Configuration
13 |
14 | Add the following lines to `seafile.conf` to keep deleted files for only 60 days:
15 |
16 | ```
17 | [history]
18 | keep_days = 60
19 | ```
20 |
21 | ## Dry-run mode
22 |
23 | To see how much garbage can be collected without actually removing any garbage, use the **dry-run** option:
24 |
25 | ```bash
26 | docker exec seatable-server /opt/seatable/scripts/seatable.sh gc --dry-run
27 | ```
28 |
29 | The output should look like:
30 |
31 | ```
32 | Starting seafserv-gc, please wait ...
33 | 2021-04-27 14:30:13 gc-core.c(904): Database is MySQL/Postgre/Oracle, use online GC.
34 | 2021-04-27 14:30:13 gc-core.c(928): Using up to 1 threads to run GC.
35 |
36 | 2021-04-27 14:30:13 gc-core.c(873): GC version 1 repo plugins repo(92ba689b-51a3-457b-a264-1e46537025c8)
37 | 2021-04-27 14:30:13 gc-core.c(609): No blocks for repo 92ba689b, skip GC.
38 |
39 | 2021-04-27 14:30:13 gc-core.c(873): GC version 1 repo My Workspace(7041b9ea-cec7-43a1-9639-70aaeb572aed)
40 | 2021-04-27 14:30:13 gc-core.c(615): GC started for repo 7041b9ea. Total block number is 14.
41 | 2021-04-27 14:30:13 gc-core.c(78): GC index size is 1024 Byte for repo 7041b9ea.
42 | 2021-04-27 14:30:13 gc-core.c(390): Populating index for repo 7041b9ea.
43 | 2021-04-27 14:30:13 gc-core.c(369): Traversed 22 commits, 14 blocks for repo 7041b9ea.
44 | 2021-04-27 14:30:13 gc-core.c(682): Scanning and deleting unused blocks for repo 7041b9ea.
45 | 2021-04-27 14:30:13 gc-core.c(700): GC finished for repo 7041b9ea. 14 blocks total, about 14 reachable blocks, 0 blocks are removed.
46 |
47 | 2021-04-27 14:30:13 gc-core.c(873): GC version 1 repo My Library Template(3fe6b035-2e0f-4c2f-9347-2673b5778e72)
48 | 2021-04-27 14:30:13 gc-core.c(609): No blocks for repo 3fe6b035, skip GC.
49 |
50 | ...
51 |
52 | 2021-04-27 14:30:13 gc-core.c(773): === Repos deleted by users ===
53 | 2021-04-27 14:30:13 gc-core.c(1041): Repo fb882070-d158-4433-a038-6be0117560e0 can be GC'ed.
54 | ...
55 | 2021-04-27 14:30:13 gc-core.c(980): === GC is finished ===
56 |
57 | 2021-04-27 14:30:13 gc-core.c(1226): The following repos have blocks to be removed:
58 | 2021-04-27 14:30:13 gc-core.c(1229): 09a91b76-df37-44d4-81e0-416e4397c9f6
59 |
60 | seafserv-gc run done
61 |
62 | Done.
63 | ```
64 |
65 | ## Removing Garbage
66 |
67 | Run a garbage collection program without adding --dry-run option to actually remove garbage block.
68 |
69 | ```
70 | docker exec seatable-server /opt/seatable/scripts/seatable.sh gc
71 | ```
72 |
--------------------------------------------------------------------------------
/docs/upgrade/migrate-seatable-editions.md:
--------------------------------------------------------------------------------
1 | # Migrate between SeaTable Editions
2 |
3 | The migration between SeaTable Enteprise Edition and SeaTable Developer Edition is easy and possible at any time. Please make sure that you only migrate between the same major and minor versions:
4 |
5 | - 3.3.7 Enterprise Edition :material-chevron-double-right: 3.3.0 Developer Edition is :white_check_mark:
6 | - 3.2.0 Developer Edition :material-chevron-double-right: 3.2.6 Enterprise Edition is :white_check_mark:
7 | - 3.3.7 Enterprise Edition :material-chevron-double-right: 3.4.0 Developer Edition is :red_square:
8 | - 3.2.0 Developer Edition :material-chevron-double-right: 3.3.7 Enterprise Edition is :red_square:
9 |
10 | You can find the available images and their versions at :material-docker: docker hub:
11 |
12 | - [Available Enterprise Editions](https://hub.docker.com/r/seatable/seatable-enterprise/tags)
13 | - [Available Developer Editions](https://hub.docker.com/r/seatable/seatable-developer/tags)
14 |
15 | !!! warning "Backup is recommended"
16 |
17 | To protect your data, it is strongly recommended to back up the database prior to the migration. See the section on [backup and recovery](../maintenance/backup-recovery.md) for details.
18 |
19 | ## Migration
20 |
21 | Basically for the migration only two things are important:
22 |
23 | - provide a seatable server license (if necessary)
24 | - switch the used docker image
25 |
26 | After a restart of the docker containers, SeaTable takes care of the rest. So let see what you have to do.
27 |
28 | ??? tip "Migrate from Enterprise Edition to Developer Edition"
29 |
30 | ## Enterprise to Developer Edition
31 |
32 | ### Stop SeaTable Server
33 |
34 | Stop all containers that are currently running.
35 |
36 | ```bash
37 | cd /opt/seatable-compose && \
38 | docker compose down
39 | ```
40 |
41 | ### Switch images
42 |
43 | Open your `/opt/seatable-compose/.env` file and add this line to use the SeaTable developer image.
44 | Make sure to replace `latest` with the correct version as described at the beginning of this article.
45 |
46 | ```bash
47 | SEATABLE_IMAGE='seatable/seatable-developer:latest'
48 | ```
49 |
50 | ### Restart SeaTable Server
51 |
52 | Just copy and paste these commands to restart seatable.
53 |
54 | ```bash
55 | cd /opt/seatable-compose && \
56 | docker compose up -d
57 | ```
58 |
59 | ??? success "Migrate from Developer Edition to Enterprise Edition"
60 |
61 | ## Developer to Enterprise Edition
62 |
63 | ### Stop SeaTable Server
64 |
65 | Stop all containers that are currently running.
66 |
67 | ```bash
68 | cd /opt/seatable-compose && \
69 | docker compose down
70 | ```
71 |
72 | ### Modify your .env file
73 |
74 | Open your .env file and search for the definition of SEATABLE_IMAGE. It should point to `seatable/seatable-developer`. Either remove this line or add the correct SeaTable Enterprise Edition.
75 |
76 | ### Provide the seatable-server licence file
77 |
78 | Save the `seatable-license.txt` to `/opt/seatable-compose`.
79 |
80 | ### Restart SeaTable Server
81 |
82 | Just copy and paste these commands to restart seatable.
83 |
84 | ```bash
85 | cd /opt/seatable-compose && \
86 | docker compose up -d
87 | ```
88 |
--------------------------------------------------------------------------------
/docs/configuration/environment-variables.md:
--------------------------------------------------------------------------------
1 | # List of available environment variables
2 |
3 | SeaTable supports environment variables for initial deployment and configuration of some settings. This is the complete list of supported settings. With every version, new variables will be added.
4 | Please note that this page only denotes environment variables used by SeaTable and its core components.
5 |
6 | ```ini
7 | # components to be used
8 | COMPOSE_FILE='caddy.yml,seatable-server.yml' # (1)!
9 | COMPOSE_PATH_SEPARATOR=','
10 |
11 | # system settings
12 | TIME_ZONE='Europe/Berlin' # (2)!
13 |
14 | # seatable server base url
15 | SEATABLE_SERVER_HOSTNAME='seatable.example.com' # (3)!
16 | SEATABLE_SERVER_PROTOCOL='https' # (4)!
17 |
18 | # initial web admin
19 | SEATABLE_ADMIN_EMAIL='me@example.com' # (5)!
20 | SEATABLE_ADMIN_PASSWORD='topsecret' # (6)!
21 |
22 | # database
23 | MARIADB_HOST='mariadb'
24 | MARIADB_PORT='3306'
25 | MARIADB_PASSWORD='topsecret' # (7)!
26 |
27 | # Redis
28 | REDIS_HOST='redis'
29 | REDIS_PORT='6379'
30 | REDIS_PASSWORD='topsecret'
31 |
32 | JWT_PRIVATE_KEY='topsecret' # (8)!
33 |
34 | # SeaDoc
35 | ENABLE_SEADOC='false'
36 | SEADOC_PORT=''
37 |
38 | # Python-Pipeline
39 | PYTHON_SCHEDULER_URL='http://python-scheduler' # (13)!
40 | PYTHON_SCHEDULER_AUTH_TOKEN='topsecret'
41 |
42 | # E-Mail
43 | SEATABLE_EMAIL_USE_TLS= # (12)!
44 | SEATABLE_EMAIL_HOST=
45 | SEATABLE_EMAIL_HOST_USER=
46 | SEATABLE_EMAIL_HOST_PASSWORD=
47 | SEATABLE_EMAIL_PORT=
48 | SEATABLE_DEFAULT_FROM_EMAIL=
49 | SEATABLE_SERVER_EMAIL=
50 |
51 | # Templates
52 | SEATABLE_SHOW_TEMPLATES_LINK= # (9)!
53 | SEATABLE_TEMPLATE_BASE_API_TOKEN=
54 | SEATABLE_TEMPLATE_TABLE_NAME=
55 | SEATABLE_ENABLE_CREATE_BASE_FROM_TEMPLATE=
56 |
57 | # SeaTable Storage Server (Cleanup of snapshots)
58 | # not yet part of the seatable-server.yml
59 | #STORAGE_SERVER_ENABLE_SNAPSHOT_CLEANUP=
60 | #STORAGE_SERVER_SNAPSHOT_CLEANUP_AT=
61 | #STORAGE_SERVER_SNAPSHOT_KEEP_DAYS=
62 | #STORAGE_SERVER_SNAPSHOT_KEEP_FREQUENCY_DAYS=
63 |
64 | # Logging
65 | SEATABLE_LOG_LEVEL=INFO # (10)!
66 | #SEATABLE_LOG_TO_STDOUT=
67 |
68 | # Docker Images
69 | # You can use these variables to override the default images
70 | SEATABLE_IMAGE=
71 | SEATABLE_DB_IMAGE=
72 | SEATABLE_REDIS_IMAGE=
73 | IMAGE_CADDY=
74 |
75 | # Miscellaneous
76 | SEATABLE_HELP_LINK=https://help.seatable.com # (11)!
77 | ```
78 |
79 | 1. COMPOSE_FILE is a comma separated list of files **without spaces**. This list defines which components should run on this server.
80 | 2. Get a [list of timezones](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) from Wikipedia.
81 | 3. Select your domain or subdomain that points to your Server (without https://). You have to set an A-Record or CNAME pointing to your IP.
82 | 4. Available options are `http` and `https`. Default value is `https`.
83 | 5. Email address of an initial admin user. Is only used during the first startup.
84 | 6. Password of an initial admin user. Is only used during the first startup.
85 | 7. Password for the root user for the MariaDB databases.
86 | 8. This private key is used to sign JWTs in SeaTable.
87 | 9. Please refer to [Templates](../customization/templates.md) for more information.
88 | 10. Allowed values are `DEBUG`, `INFO`, `WARNING`, `ERROR` and `CRITICAL`.
89 | 11. Please refer to [Manual Link](../customization/manual-in-nav.md) for more information.
90 | 12. Please refer to [Email Sending](./sending-email.md) for more information.
91 | 13. Please refer to [Python Pipeline](../installation/components/python-pipeline.md) for more information.
92 |
93 |
--------------------------------------------------------------------------------
/docs/downloads/add_mariadb_healthcheck.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | # Older mariadb containers didn't include a local healthcheck user. The container stays `unhealthy` after you execute `docker compose up -d`.
4 | # This script will create the necessary healthcheck user in the database and create a file with the credentials.
5 | # If you followed the default installation method described in manual.seatable.io, you don't have to change the following variables.
6 |
7 | echo ""
8 | echo "Let's create the healthcheck user in the database..."
9 |
10 | if ! which pwgen >/dev/null 2>&1; then
11 | echo "> It seems that pwgen is not installed. Please install this software first."
12 | fi
13 |
14 | PATH_ENV_FILE=/opt/seatable-compose/.env
15 | CONTAINER_NAME=mariadb
16 | CONTAINER_DATADIR=/opt/mariadb
17 | HEALTHCHECK_PASS=`pwgen 20 1`
18 |
19 | echo "> The password for this healthcheck user will be '${HEALTHCHECK_PASS}'. You don't have to save this password if everything goes right."
20 |
21 | echo "> I try to get the SEATABLE_MYSQL_ROOT_PASSWORD from your .env file."
22 | source /opt/seatable-compose/.env
23 | echo "> Your SEATABLE_MYSQL_ROOT_PASSWORD is '${SEATABLE_MYSQL_ROOT_PASSWORD}'."
24 |
25 | echo "> I try to create the healthcheck user in the database."
26 | CHECK_USER=$(docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "SELECT * FROM mysql.user WHERE user = 'healthcheck';")
27 |
28 | if [ $? -eq 1 ]; then
29 | echo "> I have a problem: it seems that the container is either not running or I can not write the user in the database."
30 | echo "> Script not successful."
31 | exit 1
32 | fi
33 |
34 | if [ -z "${CHECK_USER}" ]; then
35 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "CREATE USER 'healthcheck'@'127.0.0.1' IDENTIFIED BY '${HEALTHCHECK_PASS}';" && \
36 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "GRANT USAGE ON *.* TO 'healthcheck'@'127.0.0.1';" && \
37 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "CREATE USER 'healthcheck'@'::1' IDENTIFIED BY '${HEALTHCHECK_PASS}';" && \
38 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "GRANT USAGE ON *.* TO 'healthcheck'@'::1';" && \
39 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "CREATE USER 'healthcheck'@'localhost' IDENTIFIED BY '${HEALTHCHECK_PASS}';" && \
40 | docker exec ${CONTAINER_NAME} mysql -u root -p${SEATABLE_MYSQL_ROOT_PASSWORD} -e "GRANT USAGE ON *.* TO 'healthcheck'@'localhost';"
41 | echo "> I created the healthcheck user in the database."
42 | else
43 | echo "> There is already a healthcheck user in the database. Check if ${CONTAINER_DATADIR}/.my-healthcheck.cnf exists."
44 | fi
45 |
46 | if [ -e ${CONTAINER_DATADIR}/.my-healthcheck.cnf ]; then
47 | echo "> I have a problem: it seems that there is already a file with the healthcheck credentials at ${CONTAINER_DATADIR}/.my-healthcheck.cnf. I will not overwrite this..."
48 | echo "> Script not successful."
49 | exit 1
50 | else
51 | echo "> I write the .my-healtcheck.cnf file now."
52 | echo "[mariadb-client]" > ${CONTAINER_DATADIR}/.my-healthcheck.cnf
53 | echo "port=3306" >> ${CONTAINER_DATADIR}/.my-healthcheck.cnf
54 | echo "socket=/run/mysqld/mysqld.sock" >> ${CONTAINER_DATADIR}/.my-healthcheck.cnf
55 | echo "user=healthcheck" >> ${CONTAINER_DATADIR}/.my-healthcheck.cnf
56 | echo "password=${HEALTHCHECK_PASS}" >> ${CONTAINER_DATADIR}/.my-healthcheck.cnf
57 | echo "protocol=tcp" >> ${CONTAINER_DATADIR}/.my-healthcheck.cnf
58 | fi
59 |
60 | echo "> FINISH SUCCESSFUL. Your container should become healthy now."
--------------------------------------------------------------------------------
/docs/introduction/requirements.md:
--------------------------------------------------------------------------------
1 | # Requirements
2 |
3 | One of the main advantages of SeaTable against other solutions is, that you can run SeaTable on your own hardware or on any server your like. Still there are some requirements:
4 |
5 | - Linux-Server with Root-Shell
6 | - Public domain pointing to your server
7 | - Open Ports for HTTP and HTTPS access (probably more ports for other components)
8 | - The ports should not be already in use by another proxy such as NGINX or Apache
9 |
10 | Does this sounds complicated? Not really. So lets get started.
11 |
12 | [Let's begin with the installation in the root-shell](../installation/basic-setup.md){ .md-button .md-button--primary }
13 |
14 | If you need more information, you can get more details in this article.
15 |
16 | ## Platform support
17 |
18 | SeaTable uses `docker` and `docker compose`. Therefore it should run as long as docker virtualisation is available. Still we recommend **Debian 11 or newer** because we always use Debian for production and testing.
19 |
20 | Currently only x86/x64 architecture is officially supported. Bigger customers might get support with ARM based systems.
21 |
22 | ## Hardware
23 |
24 | SeaTable Server requires at least
25 |
26 | - 4 CPU cores
27 | - 8 GB RAM
28 | - 50 GB SSD
29 |
30 | These resources guarantee good performance for most applications with up to 100 users. When bases become large or the number of users increase, **more RAM** is needed since SeaTable stores the bases in memory. More CPU could help, but has much lower impact on system performance.
31 |
32 | As soon as you have more than 100 users, you should consider extending your SeaTable Platform and move some components to separate VMs.
33 |
34 | !!! warning "Additional components need additional ressources"
35 |
36 | These hardware requirements are for SeaTable Server. If you install additional components like n8n, collabora online or onlyoffice the requirements for these ressources stack up and you have to add additional ressources.
37 |
38 | For sure we need a **root shell** on this server to execute the installation commands.
39 |
40 | ## Public available domain
41 |
42 | This manual assumes that you have **one domain or subdomain** that points to your public IP address of your server.
43 |
44 | ```mermaid
45 | flowchart LR
46 | A["User / Browser"]
47 | B[Domain / Subdomain Ports 80+443]
48 | C[Server or VM with Docker]
49 | A-->B
50 | B-->C
51 | ```
52 |
53 | For sure, it is possible to run SeaTable without an internet connection (air-gapped) or with custom SSL certificates. This requires additional settings which are explained in separate chapters.
54 |
55 | ## Ports
56 |
57 | SeaTable needs by default only the default ports **80 (HTTP)** and **443 (HTTPS)**.
58 |
59 | Most of the additional components will require **additional ports** in the range of **6230 to 6240**. You have to open the firewall or create port forwardings if you want to use these functions. If you don't use this component, the port can stay closed.
60 |
61 | ### List of required ports
62 |
63 | - **80**: HTTP access is necessary to receive a Let's Encrypt certificate
64 | - **443**: HTTPS is the main entrance to SeaTable Server
65 |
66 | ### List of optional ports
67 |
68 | - **6230**: Uptime Kuma
69 | - **6231**: n8n
70 | - **6232**: Collabora Online
71 | - **6233**: OnlyOffice
72 | - **6235**: Zabbix
73 |
74 | ## License
75 |
76 | **SeaTable Enterprise Edition** requires a license to start. A free license for two years and three users can be obtained via the command line, which will be explained during the installation. Licenses with more than three users can be obtained from [SeaTable Website](https://seatable.com/prices/).
77 |
78 | **SeaTable Developer Edition** does not require a license.
79 |
--------------------------------------------------------------------------------
/docs/maintenance/debugging.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Advanced debugging by adding error messages
6 |
7 | Sometimes SeaTable does not behave like you expect it to behave. Then it is time for some advanced debugging skills. This article debugs a possible problem to give you some knowledge that might help you to solve other problems, too. To follow this explanation you should have at least some development experience.
8 |
9 | ## The problem: User not found
10 |
11 | Imagine the situation that the "Share a base with other users" does not show the users you expected.
12 |
13 | 
14 |
15 | You have no idea why the auto complete function is not working as expected. So let's find out.
16 |
17 | ## Check the Developer Tools of your browser
18 |
19 | The first check that you can perform is the Browser Console and the networking tab of your developer tools.
20 |
21 | ### The console tab
22 |
23 | In this case there are not errors in the console tab. That means there are not general JavaScript execution errors or bad Api endpoints. If you have problems inside your network like firewalls blocking traffic, unsigned certificates or something like that, you will most likely see an error in the browser console tab. In this case there is no error message.
24 |
25 | ### The network tab
26 |
27 | In the network tab, you can detect what kind of calls are executed, if you search for a user.
28 |
29 | 
30 |
31 | From the results you can see that with every key stroke SeaTable executes a command like:
32 |
33 | ```bash
34 | /api2/search-user/?q=demo
35 | ```
36 |
37 | So let's find this source code in the SeaTable Container.
38 |
39 | ## Find the Python Source Code
40 |
41 | Access your SeaTable Server container and let's search for the source code. I start my search in `dtable-web/seahub`.
42 |
43 | ```bash
44 | docker exec -it seatable-server bash
45 | cd /opt/seatable/seatable-server-latest/dtable-web/seahub
46 | grep -R "search-user" ./
47 |
48 | # the result
49 | ./api2/urls.py: re_path(r'^search-user/$', SearchUser.as_view(), name='search-user'),
50 | ```
51 |
52 | Now let's get a closer look at this `/api2/urls.py` at `/opt/seatable/seatable-server-latest/dtable-web/seahub/api2/urls.py`.
53 |
54 | There you can find at the beginning of this file, this content:
55 |
56 | ```bash
57 | from .endpoints.search_user import SearchUser
58 | ```
59 |
60 | This tells us, that the source code of this search function is in the file `/opt/seatable/seatable-server-latest/dtable-web/seahub/api2/endpoints/search_user.py`.
61 |
62 | ## Add custom error messages
63 |
64 | In this python file, I can immediately see that there is the `class SearchUser(APIView)`. In the class I can see that the code checks for some parameters like:
65 |
66 | - user.permission.can_use_global_address_book
67 | - CLOUD_MODE
68 | - is_org_context
69 |
70 | Also I can see that SeaTable first generates a list of potential users and then removes out unwanted entries. So why not check if the user we are looking for is in the full list and then removed or if the user is not in there.
71 |
72 | Let's add this additional logging at line 94. Make sure that you use the right indentation, because otherwise the python code will throw errors.
73 |
74 | ```bash
75 | ## search finished, now filter out some users
76 | logger.error("This is email_list: %s " % email_list)
77 | ```
78 |
79 | ## Check the logs
80 |
81 | Now let's restart SeaTable and check the dtable_web.log for more details.
82 |
83 | ```bash
84 | # we are still in the SeaTable Server container.
85 | seatable.sh restart
86 | tail -f /opt/seatable/logs/dtable_web.log
87 | ```
88 |
--------------------------------------------------------------------------------
/docs/maintenance/helper-scripts.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: new
3 | ---
4 |
5 | # Helper Scripts
6 |
7 | After installing SeaTable, `/opt/seatable-compose/tools` contains the following shell scripts in order to make administrative operations more convenient.
8 |
9 | ## User management
10 |
11 | ### activate-user.sh
12 |
13 | This script allows you to enable an **existing** SeaTable user inside the database.
14 | Simply provide the user's contact email address as a parameter:
15 |
16 | === "Input"
17 |
18 | ```bash
19 | ./tools/activate-user.sh "user@email.com"
20 | ```
21 |
22 | === "Output"
23 |
24 | ```
25 | --------------
26 | UPDATE ccnet_db.EmailUser SET is_active = 1 WHERE email = (SELECT user FROM dtable_db.profile_profile WHERE contact_email = 'user@email.com')
27 | --------------
28 |
29 | Query OK, 1 row affected (0.002 sec)
30 | Rows matched: 1 Changed: 1 Warnings: 0
31 |
32 | Bye
33 | Success: Activated user user@email.com
34 | ```
35 |
36 | ### deactivate-user.sh
37 |
38 | This script allows you to disable an existing SeaTable user inside the database.
39 | Simply provide the user's email address as a parameter:
40 |
41 | === "Input"
42 |
43 | ```bash
44 | ./tools/deactivate-user.sh "user@email.com"
45 | ```
46 |
47 | === "Output"
48 |
49 | ```
50 | --------------
51 | UPDATE ccnet_db.EmailUser SET is_active = 0 WHERE email = (SELECT user FROM dtable_db.profile_profile WHERE contact_email = 'user@email.com')
52 | --------------
53 |
54 | Query OK, 1 row affected (0.002 sec)
55 | Rows matched: 1 Changed: 1 Warnings: 0
56 |
57 | Bye
58 | Success: Deactivated user user@email.com
59 | ```
60 |
61 | ### user-stats.sh
62 |
63 | This script will print your current license limit and query the database for the number of enabled users:
64 |
65 | === "Input"
66 |
67 | ```bash
68 | ./tools/user-stats.sh
69 | ```
70 |
71 | === "Output"
72 |
73 | ```
74 | User limit according to license file: 3
75 |
76 | Users in database:
77 | +-------+--------------+
78 | | users | active_users |
79 | +-------+--------------+
80 | | 2 | 2 |
81 | +-------+--------------+
82 | ```
83 |
84 | ## Database management
85 |
86 | ### db-shell.sh
87 |
88 | This script will give you an interactive shell inside the MariaDB container. You can use this to directly run SQL commands.
89 |
90 | === "Input"
91 |
92 | ```bash
93 | ./tools/db-shell.sh
94 | ```
95 |
96 | === "Output"
97 |
98 | ```
99 | Welcome to the MariaDB monitor. Commands end with ; or \g.
100 | Your MariaDB connection id is 73
101 | Server version: 11.4.3-MariaDB-ubu2404 mariadb.org binary distribution
102 |
103 | Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
104 |
105 | Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
106 |
107 | MariaDB [(none)]>
108 | ```
109 |
110 | ### dump-database.sh
111 |
112 | This script will dump all three databases (`ccnet_db`, `dtable_db` and `seahub_db`) to `/opt/seatable-backup` on the host.
113 |
114 | === "Input"
115 |
116 | ```bash
117 | ./tools/dump-database.sh
118 | ```
119 |
120 | === "Output"
121 |
122 | ```
123 | Success: Dumped databases into /opt/seatable-backup
124 | ```
125 |
126 | === "Created Files"
127 |
128 | ```
129 | total 228
130 | -rw-r--r-- 1 root root 12184 May 23 11:30 ccnet_db-2025-05-23-11-30-27.sql
131 | -rw-r--r-- 1 root root 177499 May 23 11:30 dtable_db-2025-05-23-11-30-27.sql
132 | -rw-r--r-- 1 root root 38402 May 23 11:30 seafile_db-2025-05-23-11-30-27.sql
133 | ```
134 |
135 |
--------------------------------------------------------------------------------
/docs/installation/cluster/managed-services.md:
--------------------------------------------------------------------------------
1 | ---
2 | search:
3 | exclude: true
4 | ---
5 |
6 | # Managed services
7 |
8 | ```
9 | # components to be used; IMPORTANT: there should be no space between the files names !
10 | COMPOSE_FILE='mariadb.yml,redis.yml,s3.yml'
11 | COMPOSE_PATH_SEPARATOR=','
12 |
13 | # system settings
14 | TIME_ZONE='Europe/Berlin'
15 |
16 | # database
17 | SEATABLE_MYSQL_ROOT_PASSWORD='xxx'
18 | REDIS_PASSWORD='xxx'
19 |
20 | ```
21 |
22 | ## S3 with minio
23 |
24 | ```
25 | ---
26 | services:
27 | caddy:
28 | image: ${CADDY_IMAGE:-lucaslorentz/caddy-docker-proxy:2.8.11-alpine}
29 | restart: unless-stopped
30 | container_name: caddy
31 | ports:
32 | - 80:80
33 | - 443:443
34 | environment:
35 | - CADDY_INGRESS_NETWORKS=frontend-net
36 | volumes:
37 | - "/var/run/docker.sock:/var/run/docker.sock"
38 | - "/opt/caddy:/data/caddy"
39 | networks:
40 | - frontend-net
41 | healthcheck:
42 | test: ["CMD-SHELL", "curl --fail http://localhost:2019/metrics || exit 1"]
43 | start_period: 20s
44 | interval: 20s
45 | timeout: 5s
46 | retries: 3
47 |
48 | minio:
49 | container_name: minio
50 | image: minio/minio:RELEASE.2024-12-18T13-15-44Z
51 | networks:
52 | - frontend-net
53 | volumes:
54 | - '/opt/minio_data:/data'
55 | environment:
56 | - MINIO_ROOT_USER=minio
57 | - MINIO_ROOT_PASSWORD=s3_topsecret
58 | - MINIO_SERVER_URL=https://
59 | - MINIO_BROWSER_REDIRECT_URL=https:///console
60 | command: server /data --console-address ":9090"
61 | labels:
62 | caddy:
63 | caddy.redir: /console /console/
64 | caddy.reverse_proxy: "{{upstreams 9000}}"
65 | caddy.handle_path: /console/*
66 | caddy.handle_path.0_reverse_proxy: "{{upstreams 9090}}"
67 |
68 | networks:
69 | frontend-net:
70 | name: frontend-net
71 |
72 | ```
73 |
74 | ## Redis
75 |
76 | ```
77 | ---
78 | services:
79 | redis:
80 | image: ${SEATABLE_REDIS_IMAGE:-redis:7.2.7-bookworm}
81 | restart: unless-stopped
82 | container_name: redis
83 | environment:
84 | - REDIS_PASSWORD=${REDIS_PASSWORD:?Variable is not set or empty}
85 | command:
86 | - /bin/sh
87 | - -c
88 | - redis-server --requirepass "$${REDIS_PASSWORD:?REDIS_PASSWORD variable is not set}"
89 | networks:
90 | - backend-seatable-net
91 | healthcheck:
92 | test: ["CMD", "redis-cli", "ping"]
93 | interval: 20s
94 | retries: 3
95 | timeout: 5s
96 | ports:
97 | - 6379:6379
98 |
99 | networks:
100 | backend-seatable-net:
101 | name: backend-seatable-net
102 | ```
103 |
104 | ## Mariadb
105 |
106 | ```
107 | ---
108 | services:
109 | mariadb:
110 | image: ${SEATABLE_DB_IMAGE:-mariadb:11.4.3-noble}
111 | restart: unless-stopped
112 | container_name: mariadb
113 | environment:
114 | - MYSQL_ROOT_PASSWORD=${SEATABLE_MYSQL_ROOT_PASSWORD:?Variable is not set or empty}
115 | - MYSQL_LOG_CONSOLE=true
116 | - MARIADB_AUTO_UPGRADE=1
117 | - TZ=Europe/Berlin
118 | volumes:
119 | - "/opt/mariadb:/var/lib/mysql"
120 | networks:
121 | - backend-seatable-net
122 | healthcheck:
123 | test:
124 | [
125 | "CMD",
126 | "/usr/local/bin/healthcheck.sh",
127 | "--connect",
128 | "--mariadbupgrade",
129 | "--innodb_initialized",
130 | ]
131 | interval: 20s
132 | retries: 3
133 | start_period: 30s
134 | timeout: 10s
135 | ports:
136 | - 3306:3306
137 |
138 | networks:
139 | backend-seatable-net:
140 | name: backend-seatable-net
141 | ```
--------------------------------------------------------------------------------
/docs/installation/components/python-pipeline.md:
--------------------------------------------------------------------------------
1 | # Python Pipeline
2 |
3 | To run Python scripts directly within SeaTable, you need to install the Python Pipeline — an environment utilizing Docker containers for script execution and result retrieval. Thanks to SeaTable's Python API, querying and manipulating data in a SeaTable base is super easy.
4 |
5 | Explore various use cases from other SeaTable users:
6 |
7 | - Retrieve current stock prices and store them in SeaTable.
8 | - Validate DNS settings of specified domains for specific TXT entries.
9 | - Capture submissions from [Jotform](https://www.jotform.com/) or [tally](https://tally.so/) and store the results.
10 | - Identify duplicate entries and apply specific tags.
11 |
12 | Find additional Python functions and code examples in the [SeaTable Developer Manual](https://developer.seatable.com).
13 |
14 | 
15 |
16 | ## Installation
17 |
18 | This how-to explains the deployment of the Python Pipeline next to your SeaTable Server instance.
19 |
20 | !!! warning "Security Considerations"
21 |
22 | If you allow untrusted users or users with limited trust to execute Python scripts within SeaTable, you should deploy the Python Pipeline on a separate node without private network access to your SeaTable server instance.
23 | Please follow the [documentation](../advanced/python-pipeline-dedicated-server.md) on how to achieve this.
24 |
25 | #### Amend the .env file
26 |
27 | To install the Python Pipeline, append `python-pipeline.yml` to the `COMPOSE_FILE` variable within your `.env` file. This instructs Docker to download the required images for the Python Pipeline.
28 |
29 | Simply copy and paste (:material-content-copy:) the following code into your command line:
30 |
31 | ```bash
32 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,python-pipeline.yml'/" /opt/seatable-compose/.env
33 | ```
34 |
35 | !!! warning "Avoid space in `COMPOSE_FILE`"
36 |
37 | When manually adding `python-pipeline.yml` to the `COMPOSE_FILE` variable using your preferred text editor, make sure that you do not enter a space (:material-keyboard-space:). After the modification, your `COMPOSE_FILE` variable should look like this:
38 |
39 | ```bash
40 | COMPOSE_FILE='caddy.yml,seatable-server.yml,python-pipeline.yml'
41 | ```
42 |
43 | #### Generate a shared secret for secure communication
44 |
45 | For secure communication between SeaTable and the Python Pipeline, a shared secret is required to prevent unauthorized access or usage. We recommend utilizing `pwgen` to generate a robust and secure password. Copy and paste the following command into your command line to generate a password:
46 |
47 | ```bash
48 | pw=$(pwgen -s 40 1) && echo "Generated shared secret: ${pw}"
49 | ```
50 |
51 | The generated shared secret needs to be added to your `.env` file. Copy and paste the following command:
52 |
53 | ```bash
54 | echo -e "\n# python-pipeline" >> /opt/seatable-compose/.env
55 | echo "PYTHON_SCHEDULER_AUTH_TOKEN=${pw}" >> /opt/seatable-compose/.env
56 | ```
57 |
58 | #### Start the Python Pipeline
59 |
60 | Now it is time to start the Python Pipeline.
61 |
62 | ```bash
63 | cd /opt/seatable-compose && \
64 | docker stop seatable-server && \
65 | docker compose up -d
66 | ```
67 |
68 | #### Check the functionality Python Pipeline
69 |
70 | Do you want to execute your first Python script in SeaTable? Nothing easier than that.
71 |
72 | - Login to your SeaTable Server.
73 | - Create a new base and open it.
74 | - Add a Python script with the content `print("Hello World")` and execute it. If you don't know how to do this, check out our [user manual](https://seatable.io/docs/javascript-python/anlegen-und-loeschen-eines-skriptes/?lang=auto).
75 |
76 | If everything went well, you should see the output `Hello World`.
77 |
78 | 
79 |
80 | :material-party-popper: **Great!** Your SeaTable Server instance can now run Python scripts.
81 |
--------------------------------------------------------------------------------
/docs/installation/deployment-approach.md:
--------------------------------------------------------------------------------
1 | # Deployment Approach
2 |
3 | A SeaTable Server consists of multiple containers. Therefore let's talk about how you typically install such a system.
4 |
5 | ## Multi-container installations can be intricate
6 |
7 | Usually, software relying on multiple containers involves a large and complex `docker-compose.yml` file. This complexity intensifies with optional containers, leading to bloated files or the need to manually manage additional services. This is quite a challenging task.
8 |
9 | In addition, consistently maintaining correct indentation and syntax alignment in the YAML file demands caution. In summary, this process can be cumbersome, prone to errors, and challenging—particularly for beginners or users unfamiliar with docker-compose files.
10 |
11 | ## We want to keep it simple ...
12 |
13 | Instead of handling one extensive `docker-compose.yml` file, we present a more structured approach:
14 |
15 | - We provide a set of individual yml files and one `.env` file.
16 | - Each yml file defines commands for installing a specific component, such as the SeaTable Server, web proxy (caddy), or python pipeline.
17 | - An accompanying `.env` file manages environment variables to configure your setup.
18 |
19 | ## Layered structure
20 |
21 | Think of the `.env` file as a recipe for your setup and the yml files are like ingredients.
22 |
23 | !!! danger "Create copy for custom changes of the yml files"
24 |
25 | Generally, there's no need to modify the YAML files. We provide updated YAML files with each new SeaTable version. However, if you wish to make alterations, create a copy and name it something like `custom-.yml`.
26 |
27 | You can configure components in the `.env` file, determining which ones to install. Start with essential components like SeaTable Server and Caddy web proxy.
28 |
29 | Example in the `.env` file:
30 |
31 | ```bash
32 | COMPOSE_FILE='caddy.yml,seatable-server.yml'
33 | ```
34 |
35 | By adding or removing yml files from this list, you control the composition during runtime, eliminating the need for a single, extensive `docker-compose.yml` file.
36 |
37 | 
38 |
39 | With this understanding, the subsequent installation descriptions should be straightforward to follow.
40 |
41 | !!! success "Primarily, use copy and paste"
42 |
43 | Throughout the installation process, we strive to eliminate the need for manual file editing. Most commands can be executed by simply copying and pasting. Look for the copy-and-paste icon (:material-content-copy:) at the end of each code box, which conveniently copies the content to your clipboard. This helps prevent typing errors and ensures a smoother installation experience.
44 |
45 | ## Additional Components
46 |
47 | Like the basic installation, the installation of the additional components will be easy and straight forward. Additional components are solutions that either extend the functionality of SeaTable or help your during your daily live.
48 |
49 | These are the assumptions that we assume:
50 |
51 | - Your SeaTable Basic Setup is up and running
52 | - Your server is public reachable and you use a let's encrypt certificate
53 | - Additional services are provided by port (and not by subdomain or subfolder)
54 | - If you block incoming traffic with a firewall, you have to open some ports to make the solution reachable over the internet.
55 |
56 | ## Used Ports
57 |
58 | This is the list of ports that the components use. You only have to open them if you want
59 |
60 | - SeaTable: 80 and 443
61 | - N8n: 6231
62 | - Collabora: 6232
63 | - OnlyOffice: 6233
64 | - Uptime Kuma: 6230
65 | - Zabbix: 6235
66 | - Whiteboard (tldraw): 6239
67 | - Report Design (seadoc): 6240
68 | - Gatus Monitoring: 6220
69 | - Dozzle Log Viewer: 6241
70 |
71 | ## Separate server or subdomain
72 |
73 | This is possible for sure. Right now the installation follows the assumption from the top. You will find articles in the **Advanced Setup** explaining how to use custom certificates, custom domains or separate servers.
74 |
--------------------------------------------------------------------------------
/docs/installation/advanced/s3-migration.md:
--------------------------------------------------------------------------------
1 | # Migration from local storage to S3
2 |
3 |
4 |
5 | SeaTable provides migration scripts to migrate the data from local storage to S3. In fact three things have to be migrated:
6 |
7 | - Storage data (Snapshots and persisted json files)
8 | - Seafile data (Files/Images Columns)
9 | - Avatars
10 |
11 | Thumbnails and temporary files could not be saved to S3, yet.
12 |
13 | The migration scripts are delivered with the SeaTable Docker Container and are stored in the folder `/templates/`.
14 |
15 | ## How to migrate
16 |
17 | ### Storage data & Seafile data
18 |
19 |
20 |
21 | 1. You need four buckets: Let's call them _fs_, _blocks_, _commits_, _storage_.
22 | 2. Generate credentials to access these buckets with read and write permissions.
23 | 3. use these commands to enter your SeaTable Docker Container (4.3 or higher) and to start with the preparation for the migration. (this is not yet the migration)
24 |
25 | ```bash
26 | docker exec -it seatable-server bash
27 | cd /templates
28 | ./migrate-seafile-data.sh
29 | ./migrate-storage-data.sh
30 | ```
31 |
32 | These two commands will copy your current configuration files to a backup folder.
33 |
34 | Now add your S3 configuration to your config files `seafile.conf` and `dtable-storage-server.conf`. Use the instructions from [this article](s3.md).
35 | Be careful, due to historical reasons the settings are different for `seafile.conf` and `dtable-storage-server.conf`.
36 |
37 | Now it is time to execute the two commands again. This will start the migration of the data.
38 | **Important:** it is not yet necessary to restart SeaTable. You don't want to activate the new settings.
39 |
40 | ```bash
41 | docker exec -it seatable-server bash
42 | cd /templates
43 | ./migrate-seafile-data.sh
44 | ./migrate-storage-data.sh
45 | ```
46 |
47 | After the migration has finished, you can [restart SeaTable](../../maintenance/restart-seatable.md)
48 |
49 | ### Avatars
50 |
51 |
52 |
53 | Before you can start the migration, you have to configure S3 for Avatars in `dtable_web_settings.py`. At this point it is sufficient to add only the configuration parameters starting with `S3_...`. The configuration option `AVATAR_FILE_STORAGE = ...` is not necessary, yet.
54 |
55 | After a restart of SeaTable you can start the migration with this command:
56 |
57 | ```bash
58 | docker exec -it seatable-server bash
59 | cd /opt/seatable/seatable-server-latest/dtable-web
60 | seatable.sh python-env manage.py migrate_avatars_fs2s3
61 | ```
62 |
63 | You will see how many avatars were migrated and when the migration will be finished:
64 |
65 | ```bash
66 | # like this...
67 | 2024-06-17 ... migrate_avatars_fs2s3 - Success: 1, exists: 0, error: 0, count: 1
68 | 2024-06-17 ... migrate_avatars_fs2s3 - Migrate done
69 | ```
70 |
71 | After successful migration, you can add `AVATAR_FILE_STORAGE = 'django_s3_storage.storage.S3Storage'` to your `dtable_web_settings.py` and restart **SeaTable** and **redis**.
72 |
73 | After the migration is done, you can delete the old avatars directories below `/opt/seatable-server/seatable/seahub-data/avatars`. Don't delete the avatars folder itself and don't delete the default logos `default.png` and `app.png`. They are still used.
74 |
75 | !!! warning "Security headers might prevent the loading of the images"
76 |
77 | After activating S3 for avatars, the avatars are loaded directly from the S3 storage like ``.
78 |
79 | Security header configuration in your `seatable-server.yml` might prevent this and you need your S3 url to the Content-Security-Policy.
80 |
81 | ```
82 | caddy.header.Content-Security-Policy:
83 | ...
84 | img-src 'self' data: blob: ...
85 | ```
86 |
87 | !!! danger "Avatar bucket must be publicly accessible"
88 |
89 | While other S3 buckets used by SeaTable can remain private, the S3 bucket for avatars must be publicly readable. Once avatars are saved to S3, they are accessed directly from the S3 storage. Therefore, it is necessary to grant read access to everyone (anonymous access) while restricting write access to authenticated users with bucket credentials.
90 |
--------------------------------------------------------------------------------
/docs/configuration/seafile-conf.md:
--------------------------------------------------------------------------------
1 | # Configuration of Seafile
2 |
3 | This is a cheat sheet for the [seaf-server](/introduction/architecture/#seaf-server) configuration file `seafile.conf`. It contains all possible settings that can be configured as well as their default values.
4 |
5 | The default values provided here are best-effort (not built automatically). They will be used, if no value is defined at all. It is not necessary the value, that is written in the configuration file on first startup.
6 |
7 | In the default values below, a value in the form `$XYZ` refers to an environment variable.
8 |
9 | ??? tip "Configuration changes require a restart"
10 |
11 | New configuration options will only apply after a restart of SeaTable.
12 |
13 | ??? abstract "Notes about the configuration file format"
14 |
15 | The configuration file uses the **INI format**, which is a simple text-based format for storing configuration data. It consists of sections (denoted by square brackets, e.g., [general]) and key-value pairs.
16 |
17 | Comments in the configuration file start with the hash symbol `#` and extend to the end of the line.
18 |
19 | When dealing with special characters like single quotes `'`, double quotes `"` or the hash symbol `#`, it's generally best to enclose the value in double quotes.
20 |
21 | The following options are grouped by their sections.
22 |
23 | ## Example configuration
24 |
25 | This is a typical configuration file, created automatically on the first startup by SeaTable.
26 |
27 | ```ini
28 | [fileserver]
29 | port=8082
30 |
31 | [history]
32 | keep_days = 60
33 | ```
34 |
35 | ## Available configuration options
36 |
37 | ### `[fileserver]`
38 |
39 | | Parameter | Description | Default |
40 | | ---------------- | -------------------------------------------------------------------------------------------------- | ------- |
41 | | `host` | The address the fileserver listens on. You can set this to `127.0.0.1` to further restrict access. | 0.0.0.0 |
42 | | `port` | The port the fileserver listens on. | 8082 |
43 | | `worker_threads` | The number of worker threads used to serve HTTP requests. | 10 |
44 | | `max_download_dir_size` | Maximum size of the assets in a base that could be exported via command line in MB. | 100 |
45 |
46 | ### `[history]`
47 |
48 | | Parameter | Description | Default |
49 | | ----------- | ---------------------------------------------- | ------- |
50 | | `keep_days` | How many days the file history should be kept. | 60 |
51 |
52 | ### `[database]`
53 |
54 | Since version 5.3, Seafile reads the main database configuration settings from [environment variables](/configuration/environment-variables).
55 |
56 | The following options are optional and can be used to further tweak Seafile:
57 |
58 | | Parameter | Description | Default |
59 | | -------------------- | ----------------------------------------------------- | ------- |
60 | | `connection_charset` | The connection charset to use. | |
61 | | `max_connections` | Size of the connection pool for database connections. | 100 |
62 |
63 | ## Deprecated or removed options
64 |
65 | ### `[database]`
66 |
67 | ??? note "[database] is not necessary anymore"
68 |
69 | Since version 5.3, `Seafile` reads the main database settings from [environment variables](/configuration/environment-variables).
70 |
71 | The section `[database]` contained options for accessing the MariaDB database used by `Seafile`.
72 |
73 | - `type`: Database connection type. Use `mysql` for MySQL and MariaDB. Other databases are not yet supported.
74 | - `host`: Address of database. You must provide this option.
75 | - `port`: Port of database. Defaults to 3306.
76 | - `username`: Username for login to the database. You must provide this option.
77 | - `password`: Password for the database user. You must provide this option.
78 | - `db_name`: Database name used by `seafile_db`. You must provide this option.
79 |
--------------------------------------------------------------------------------
/docs/installation/cluster/basic-setup-with-external-services.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Basic Setup of a SeaTable Cluster
6 |
7 | SeaTable currently does not support installing a cluster with a single command. This may change in the future, but for now, some configuration changes and migrations are required after deploying the Docker containers.
8 |
9 | Every SeaTable Cluster installation starts with the deployment of a single node. The main difference is that, from the beginning, you use external services instead of running Redis and MariaDB on the same machine as SeaTable.
10 | Arterwards we will move component after component to other nodes.
11 |
12 | 
13 |
14 | ## Basic setup with external services
15 |
16 | Follow the [installation instructions for a single node](../basic-setup.md) up to the point where you would start your SeaTable Server for the first time. Before starting the server, you need to make some additional changes to your setup.
17 |
18 | ??? success "Use external services instead of local MariaDB and Redis"
19 |
20 | Update your `.env` file to include the required variables for `REDIS` and `MARIADB`. Set passwords, IPs, and usernames according to your environment. This ensures that your SeaTable Server connects to these external services.
21 |
22 | ```
23 | # components to be used; IMPORTANT: there should be no space between
24 | # the files names!
25 | COMPOSE_FILE='caddy.yml,dtable-web.yml'
26 | COMPOSE_PATH_SEPARATOR=','
27 |
28 | # system settings
29 | TIME_ZONE='Europe/Berlin'
30 |
31 | # seatable server url
32 | SEATABLE_SERVER_HOSTNAME='cluster.seatable.com
33 | SEATABLE_SERVER_PROTOCOL='https'
34 |
35 | # initial web admin
36 | SEATABLE_ADMIN_EMAIL='cluster@seatable.com'
37 | SEATABLE_ADMIN_PASSWORD='topsecret'
38 |
39 | # database (managed service)
40 | MARIADB_HOST=10.0.0.99
41 | MARIADB_USER=root
42 | MARIADB_PASSWORD='topsecret'
43 |
44 | # redis (managed service)
45 | REDIS_HOST=10.0.0.99
46 | REDIS_PORT=6379
47 | REDIS_PASSWORD='topsecret'
48 |
49 | # shared secret for secure communication
50 | JWT_PRIVATE_KEY='topsecret'
51 | ```
52 |
53 | ??? success "Remove Redis and Mariadb from your YAML file."
54 |
55 | Create a copy of `seatable-server.yml` and name it, for example, `dtable-web.yml`. Make the following changes to this file:
56 |
57 | - Remove the `depends_on:` entries for Redis and MariaDB.
58 | - Remove the `backend-seatable-net` network, as it is no longer needed.
59 |
60 | Example configuration:
61 |
62 | ```
63 | ---
64 | services:
65 | seatable-server:
66 | image: ${SEATABLE_IMAGE:-seatable/seatable-enterprise:x.x.x}
67 | restart: unless-stopped
68 | container_name: seatable-server
69 | volumes:
70 | ...
71 | environment:
72 | ...
73 | labels:
74 | ...
75 | networks:
76 | - frontend-net
77 |
78 | networks:
79 | frontend-net:
80 | name: frontend-net
81 | ```
82 |
83 | Now, you can run `docker compose up -d` for the first time.
84 |
85 | After starting, verify that only these two Docker containers are running on the SeaTable node:
86 |
87 | - caddy
88 | - seatable-server
89 |
90 | Log in with your defined admin credentials for the first time to check, that the deployment was successful.
91 |
92 | ## Migration to S3 storage
93 |
94 | Follow the instructions in the admin manual to [migrate from local storage to S3](../advanced/s3-migration.md) for the following data types:
95 |
96 | - Base snapshots
97 | - Files and pictures
98 | - Avatars
99 |
100 | Verify that everything is working by performing these steps:
101 |
102 | - Create a new base. After a few minutes, you should see the `current` directory in the S3 bucket for storage.
103 | - Create a new file/image column in the base and upload a file. You should see new entries in the S3 buckets for `fs`, `commits`, and `blocks`.
104 | - Upload a new avatar. This should be stored in the S3 bucket for `avatars`.
105 |
106 | Once you have verified that everything is working, you can continue with the deployment.
107 |
--------------------------------------------------------------------------------
/docs/installation/components/n8n.md:
--------------------------------------------------------------------------------
1 | # Automation platform n8n
2 |
3 | SeaTable empowers users and teams to store, manage, and visualize structured data efficiently, offering multiple data input options from manual entry to web forms and a comprehensive API. This flexibility ensures seamless data collection while allowing users to define automated workflows with triggers and actions.
4 |
5 | However, for those seeking additional software solutions or more sophisticated automation workflows, n8n provides the perfect complement. By integrating SeaTable with n8n, users can unlock even more powerful automation capabilities.
6 |
7 | n8n serves as an automation platform, enabling seamless connectivity between SeaTable and hundreds of other software products. Need to collect data from multistep web forms using JotForm, Typeform, or Form.io? No problem. Simply create your web forms and utilize n8n to seamlessly transfer survey results to SeaTable.
8 |
9 | Give [n8n](https://n8n.io) a try, and we guarantee you'll fall in love with it just like we have! :heart:
10 |
11 | !!! tip "Want to watch a step-by-step video instead of reading a manual?"
12 |
13 | Watch a brief English video demonstrating all the essential steps:
14 |
15 | :fontawesome-brands-youtube:{ style="color: #EE0F0F" }
16 | __[Easy n8n Installation on SeaTable]__ :octicons-clock-24: 10m
17 | [Easy n8n Installation on SeaTable]: https://www.youtube.com/watch?v=_mkA410VDT4
18 |
19 | ## Installation
20 |
21 | This article shows you how to install **n8n** (Community Edition) on your SeaTable server.
22 |
23 | #### Change the .env file
24 |
25 | Like with all additional components you first have to add the `n8n.yml` to the `COMPOSE_FILE` variable in your `.env` file.
26 |
27 | Simply copy and paste (:material-content-copy:) the following code into your command line:
28 |
29 | ```bash
30 | sed -i "s/COMPOSE_FILE='\(.*\)'/COMPOSE_FILE='\1,n8n.yml'/" /opt/seatable-compose/.env
31 | ```
32 |
33 | #### Generate secrets for your postgres database
34 |
35 | Now let's create inital secrets and write them into the .env file.
36 |
37 | ```
38 | echo -e "\n# n8n" >> /opt/seatable-compose/.env
39 | echo "N8N_ENCRYPTION_KEY=$(pwgen -s 40 1)" >> /opt/seatable-compose/.env
40 | echo "POSTGRES_PASSWORD=$(pwgen -s 40 1)" >> /opt/seatable-compose/.env
41 | echo "POSTGRES_NON_ROOT_PASSWORD=$(pwgen -s 40 1)" >> /opt/seatable-compose/.env
42 | ```
43 |
44 | #### Start n8n
45 |
46 | Now it is time to start n8n for the first time.
47 |
48 | ```bash
49 | cd /opt/seatable-compose && \
50 | docker compose up -d
51 | ```
52 |
53 | **Congratulations!** Your n8n server is ready to use.
54 |
55 | ## Initial setup
56 |
57 | #### Create initial admin user
58 |
59 | To set up your initial admin user, n8n offers a convenient Web UI accessible at `https://:6231`.
60 |
61 | 
62 |
63 | Please note that the Community Edition of n8n only permits the creation of multiple accounts with just one admin account. Further details regarding the features of this version will be elaborated later in this article.
64 |
65 | ## Limitations of the Community Edition of n8n
66 |
67 | The installed n8n version on this server is the self-hosted free Community Edition, which aligns with the **Starter Cloud version**.
68 |
69 | It offers:
70 |
71 | - Unlimited executions
72 | - Unlimited active workflows
73 | - No execution time limit
74 | - Support for all existing nodes
75 |
76 | However, there are some limitations to be aware of:
77 |
78 | - Only one admin account is allowed
79 | - Variables are not supported (consider using SeaTable instead)
80 | - External Secrets and Environments are not supported
81 | - Single Sign-On (SSO) and LDAP is not supported
82 | - Log Streaming is not supported
83 |
84 | For further information, visit the [n8n forum](https://community.n8n.io/t/feedback-self-hosted-pricing/22727/56).
85 |
86 | If you find n8n useful (which you most likely will), consider [purchasing an Enterprise license](https://n8n.io/pricing/).
87 |
88 | ## Next steps
89 |
90 | Create your first workflow in n8n, add your first node and search for `SeaTable`. Currently SeaTable supports three triggers and 16 actions.
91 | Alternatively check the docs of n8n at [https://docs.n8n.io/](https://docs.n8n.io/) for more details or do their [text courses](https://docs.n8n.io/courses/) to get a better understanding of n8n.
92 |
--------------------------------------------------------------------------------
/docs/maintenance/logs.md:
--------------------------------------------------------------------------------
1 | ---
2 | status: wip
3 | ---
4 |
5 | # Logs
6 |
7 | ## Log files of SeaTable server
8 |
9 | The SeaTable logs are under `/shared/seatable/logs` in the docker, or `/Your SeaTable data volume/seatable/logs` in the server that run the docker.
10 |
11 | Main log files:
12 |
13 | - dtable_web.log: logs for dtable-web
14 | - dtable-events.log: logs for dtable-events
15 | - dtable_events_io.log: logs for Base's import or export and Excel or CSV file import or export
16 | - dtable_events_message.log: logs for sending emails in the dtable-events background
17 | - dtable-server.log: logs for dtable-server
18 | - dtable-db.log: logs for dtable-db
19 | - dtable-db-error.log: error logs for dtable-db
20 | - dtable-db-access.log: query log for dtable-db
21 | - dtable-db-slow.log: slow query log for dtable-db
22 |
23 | Other log files:
24 |
25 | - seafile.log: logs of Seafile server
26 | - slow_logs: Slow request logs, which can be used to debug performance issues
27 | - monitor.log: Monitor logs, monitor.sh can auto restart the unexpectedly closed server
28 | - init.log: Logs for docker initialization script
29 |
30 | ## Log files of Nginx server
31 |
32 | The Nginx logs are under `/shared/nginx-logs`, or `/Your SeaTable data volume/nginx-logs` in the server that run the docker.
33 |
34 | - dtable-web.access.log
35 | - dtable-web.error.log
36 | - access.log
37 | - error.log
38 |
39 | ## Logrotate
40 |
41 | SeaTable's Docker container executes nightly log rotation cron jobs for both SeaTable and nginx logs. The cron jobs are configured as follows:
42 |
43 | ```
44 | 54 23 * * * /usr/sbin/logrotate -vf /templates/logrotate-conf/seatable-nginx 2>> /opt/seatable/logs/logrotate.log
45 | 55 23 * * * /usr/sbin/logrotate -vf /templates/logrotate-conf/seatable 2>> /opt/seatable/logs/logrotate.log
46 | ```
47 |
48 | ### Logrotate Configuration
49 |
50 | The log rotation configuration is straightforward and includes the following parameters:
51 |
52 | ```
53 | {
54 | daily
55 | missingok
56 | rotate 7
57 | # compress
58 | # delaycompress
59 | dateext
60 | dateformat .%Y-%m-%d
61 | notifempty
62 | create 644 root root
63 | sharedscripts
64 | postrotate
65 | if [ -f /opt/seatable/pids/seafile.pid ]; then
66 | kill -USR1 `cat /opt/seatable/pids/seafile.pid`
67 | fi
68 |
69 | if [ -f /opt/seatable/pids/dtable-db.pid ]; then
70 | kill -USR1 `cat /opt/seatable/pids/dtable-db.pid`
71 | fi
72 |
73 | if [ -f /opt/seatable/pids/dtable-storage-server.pid ]; then
74 | kill -USR1 `cat /opt/seatable/pids/dtable-storage-server.pid`
75 | fi
76 |
77 | if [ -f /opt/seatable/pids/api-gateway.pid ]; then
78 | kill -USR1 `cat /opt/seatable/pids/api-gateway.pid`
79 | fi
80 |
81 | if [ -f /opt/seatable/pids/dtable-web.pid ]; then
82 | pkill -HUP gunicorn
83 | fi
84 |
85 | find /opt/seatable/logs/ -mtime +7 -name "*.log*" -exec rm -f {} \;
86 | endscript
87 | }
88 | ```
89 |
90 | This configuration ensures:
91 |
92 | - Daily log rotation.
93 | - Retention of logs for seven days.
94 | - Addition of timestamps to rotated logs using dateext.
95 | - Automatic removal of old logs older than seven days.
96 |
97 | All relevant configuration files are located in `/templates/logrotate-conf` within the SeaTable Docker container.
98 |
99 | ### Customizing Logrotate Configuration
100 |
101 | To modify the log rotation settings, you can mount a custom configuration file using Docker Compose. Add the following snippet to your yml-file:
102 |
103 | ```
104 | services:
105 | seatable-server:
106 | image: ...
107 | ...
108 | volumes:
109 | - "./logrotate-seatable-custom.conf:/templates/logrotate-conf/seatable:ro"
110 | ...
111 |
112 | ```
113 |
114 | !!! warning "Don't change the default YML-files"
115 |
116 | Avoid making changes directly to `seatable-server.yml`, as this file will be overwritten during updates. Instead, use a separate custom configuration file mounted via Docker Compose.
117 |
118 | ```bash
119 | # create a custom copy
120 | cp seatable-server.yml custom-seatable-server.yml
121 |
122 | # Don't forget to update the filename in your .env
123 | ```
124 |
--------------------------------------------------------------------------------
/docs/customization/main-color.md:
--------------------------------------------------------------------------------
1 | # Change the main color
2 |
3 | SeaTable has an orange main color with the color-code `#FF8000`. If this color does not match your custom logo, it might be useful to replace this main color with another color of your choice.
4 |
5 | To do this we force SeaTable to use custom css code to overwrite the main color.
6 |
7 | The first step is you use the following color picker and select a new main color of your choice.
8 |
9 | !!! success "Dark colors are better than bright ones"
10 |
11 | You should select a color that is dark enough to be a good background for white font color. To switch also the font color from white to black is not yet part of this manual.
12 |
13 | !!! warning "Web interface overrule config files"
14 |
15 | Please be aware that if you define a value in the webinterface, this always overrules the value in the config file.
16 |
17 | === "Version 5.3"
18 |
19 | Select a color and you will get the correspondent css code in the following grey box.
20 |
21 |
22 |
23 | ```
24 | Select a color and the css code will be created...
25 | ```
26 |
27 |
28 | Use the copy-and-paste icon (:material-content-copy:) on the top right of the grey box to copy the complete css code to your clipboard.
29 |
30 | === "Version 5.2"
31 |
32 | Select a color and you will get the correspondent css code in the following grey box.
33 |
34 |
35 |
36 | ```
37 | Select a color and the css code will be created...
38 | ```
39 |
40 |
41 | Use the copy-and-paste icon (:material-content-copy:) on the top right of the grey box to copy the complete css code to your clipboard.
42 |
43 | === "Version 5.1"
44 |
45 | Select a color and you will get the correspondent css code in the following grey box.
46 |
47 |
48 |
49 | ```
50 | Select a color and the css code will be created...
51 | ```
52 |
53 |
54 | Use the copy-and-paste icon (:material-content-copy:) on the top right of the grey box to copy the complete css code to your clipboard.
55 |
56 | === "Version 5.0"
57 |
58 | Select a color and you will get the correspondent css code in the following grey box.
59 |
60 |
61 |
62 | ```
63 | Select a color and the css code will be created...
64 | ```
65 |
66 |
67 | Use the copy-and-paste icon (:material-content-copy:) on the top right of the grey box to copy the complete css code to your clipboard.
68 |
69 | === "Version 4.3"
70 |
71 | Select a color and you will get the correspondent css code in the following grey box.
72 |
73 |
74 |
75 | ```
76 | Select a color and the css code will be created...
77 | ```
78 |
79 |
80 | Use the copy-and-paste icon (:material-content-copy:) on the top right of the grey box to copy the complete css code to your clipboard.
81 |
82 | ## Configuration via the web interface
83 |
84 | Login to your SeaTable Server as system administrator and switch to the system admin area. Select the navigation point `Settings`. Team admins or normal users does not have the permission to access the system admin area.
85 |
86 | First you should set the checkbox for `ENABLE_BRANDING_CSS`. Then simply copy and paste (:material-content-copy:) the css code and paste it to the input box of `Custom CSS`. Submit by clicking on the green :material-check:.
87 |
88 | Reload your page of your browser and the color should be changed.
89 |
90 | ## Configuration via config file
91 |
92 | Open the configuration file `dtable_web_settings.py` and add this configuration line:
93 |
94 | ```bash
95 | BRANDING_CSS = 'custom/custom.css'
96 | ```
97 |
98 | Now copy the css code from this manual and save it to `/opt/seatable-server/seatable/seahub-data/custom/custom.css`. If the directory `custom` does not exist, you have to create it first.
99 |
100 | If your new color is not immediately visible after a page reload, you have to restart the SeaTable container (not the SeaTable service).
101 | The SeaTable container has to create a symlink to make the css file available to SeaTable.
102 |
--------------------------------------------------------------------------------
/docs/installation/advanced/python-pipeline-configuration.md:
--------------------------------------------------------------------------------
1 | ## Configuration
2 |
3 | The Python Pipeline can be configured through environment variables for further customization. The available parameters inside your `.env` file are:
4 |
5 | ### Resources
6 |
7 | | Parameter | Description | Default |
8 | | ----------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------- |
9 | | `PYTHON_PROCESS_TIMEOUT` | The timeout for a single script (in seconds) | `60` |
10 | | `PYTHON_TRANSFER_DIRECTORY_PATH` | The directory on the host where python-starter creates a folder for each individual script job | `/tmp` |
11 | | `PYTHON_RUNNER_CONTAINER_CPUS` | The number of CPUs available to each script container | `1` |
12 | | `PYTHON_RUNNER_CONTAINER_MEMORY` | The amount of memory available to each script container | `1g` |
13 | | `PYTHON_RUNNER_READ_ONLY_FILESYSTEM` | Whether the root filesystem should be mounted as read-only (`true` or `false`) | `true` |
14 | | `PYTHON_RUNNER_TMPFS_MOUNT_SIZE_IN_BYTES` | Maximum size of the `tmpfs` mount (mounted at `/tmp` inside the container) for each script container (in bytes) | `104857600` (100MB) |
15 | | `PYTHON_RUNNER_DROPPED_CAPABILITIES` | Comma-separated list of capabilities that should be removed from the container. Please refer to the [Docker documentation](https://docs.docker.com/engine/containers/run/#runtime-privilege-and-linux-capabilities) for more details | `CAP_NET_RAW` |
16 | | `PYTHON_RUNNER_NO_NEW_PRIVILEGES` | Whether container processes should be prevented from gaining additional privileges | `true` |
17 |
18 | ### Logging
19 |
20 | | Parameter | Description | Default |
21 | | ---------------------------- | ------------------------------------------------------------------------------------------ | --------- |
22 | | `PYTHON_SCHEDULER_LOG_LEVEL` | The log level for the python-scheduler (`DEBUG`, `INFO`, `WARNING`, `ERROR` or `CRITICAL`) | `WARNING` |
23 | | `PYTHON_STARTER_LOG_LEVEL` | The log level for the python-starter (`DEBUG`, `INFO`, `WARNING`, `ERROR` or `CRITICAL`) | `WARNING` |
24 |
25 | ## Limiting Volume Size
26 |
27 | By default, any script container can use up all of the available storage resources on your disk.
28 |
29 | You can use the following instructions to set a limit for the directory that contains all volumes. These commands should be executed on your host.
30 |
31 | ```bash
32 | # Create an empty file
33 | touch python-pipeline-volume
34 |
35 | # Resize the file (e.g. 2GB)
36 | truncate -s 2G python-pipeline-volume
37 |
38 | # Create a new ext4 filesystem
39 | mke2fs -t ext4 -F python-pipeline-volume
40 |
41 | # Create a new directory which will serve as the data transfer directory
42 | mkdir /opt/python-pipeline-transfer
43 |
44 | # Mount the filesystem
45 | mount python-pipeline-volume /opt/python-pipeline-transfer
46 |
47 | # Validate your changes
48 | df -h /opt/python-pipeline-transfer
49 | ```
50 |
51 | Afterwards, you should update your `.env` file and restart the python-starter by running `docker compose up -d`:
52 |
53 | ```ini
54 | PYTHON_TRANSFER_DIRECTORY_PATH='/opt/python-pipeline-transfer'
55 | ```
56 |
--------------------------------------------------------------------------------