Deployment Overview of SeaTable on Server¶
Prerequisites and Basic Requirements¶
The deployment process requires a Debian-based operating system with root privileges. The following components must be available on the server:
- Operating System: Debian or a compatible distribution.
- Privileges: Root access or
sudoprivileges to install system packages and manage Docker. - Network: Access to the internet to download Docker and the SeaTable release archive.
- Ports: The application utilizes standard web ports managed by the Caddy proxy container.
File and Directory Structure¶
All application files, configurations, and data are located within the /opt/seatable-compose directory. The structure includes:
/opt/seatable-compose/: The primary working directory for the SeaTable deployment./opt/seatable-compose/.env: The environment configuration file containing database passwords, hostnames, and image versions./opt/seatable-compose/.env-release: The default template file used to initialize the.envconfiguration./opt/seatable-compose/seatable-license.txt: A placeholder file for license management./opt/seatable-compose/caddy.yml: The Docker Compose file defining the Caddy reverse proxy./opt/seatable-compose/seatable-server.yml: The Docker Compose file defining the SeaTable server and its dependencies.
Application Installation Process¶
The SeaTable application is deployed using Docker Compose. The installation involves downloading the latest release archive and extracting it to the designated directory.
- Update the system package cache and install
curl. - Install Docker using the official installation script.
- Create the working directory at
/opt/seatable-compose. - Download the latest release archive from
https://github.com/seatable/seatable-release/releases/latest/download/seatable-compose.tar.gz. - Extract the archive contents into
/opt/seatable-compose. - Initialize the configuration by copying
.env-releaseto.envif the latter does not exist.
Docker Containers and Their Deployment¶
The application runs as a set of Docker containers managed by Docker Compose. The deployment utilizes two specific compose files defined in the environment configuration:
caddy.yml: Manages the Caddy reverse proxy container.seatable-server.yml: Manages the SeaTable server, MariaDB database, and Redis cache containers.
The environment variable COMPOSE_FILE is set to 'caddy.yml,seatable-server.yml' and COMPOSE_PATH_SEPARATOR is set to ',' to allow Docker Compose to load both files simultaneously.
The SeaTable image used for the server is specified as seatable/seatable-developer:latest in the .env file.
Proxy Servers¶
The deployment includes a Caddy container acting as a reverse proxy. This container handles incoming web traffic and manages SSL/TLS termination. The configuration is defined within the caddy.yml file, which is loaded alongside the server configuration.
Databases¶
The application relies on two internal database services managed within the Docker Compose environment:
- MariaDB: Used for persistent data storage. The password is configured via the
MARIADB_PASSWORDvariable in the.envfile. - Redis: Used for caching and session management. The password is configured via the
REDIS_PASSWORDvariable in the.envfile.
Both services run as containers within the same network as the SeaTable server.
Access Rights and Security¶
Security settings are managed through environment variables in the .env file. The following variables must be configured:
SEATABLE_SERVER_HOSTNAME: Defines the domain name for the application.SEATABLE_ADMIN_EMAIL: Sets the email address for the initial administrator account.SEATABLE_ADMIN_PASSWORD: Sets the password for the initial administrator account.JWT_PRIVATE_KEY: Configures the private key for JSON Web Token authentication.MARIADB_PASSWORD: Sets the root password for the MariaDB container.REDIS_PASSWORD: Sets the password for the Redis container.TIME_ZONE: Automatically set to match the server's system timezone.
Starting, Stopping, and Updating¶
The application is started, stopped, and updated using Docker Compose commands executed from the /opt/seatable-compose directory.
- Start: To launch the containers, run the following command:
- Stop: To stop the running containers, use:
- Update: To update the application to the latest version, re-download the release archive, extract it to overwrite existing files, and restart the containers using the start command.