Skip to content

Commit

Permalink
Merge pull request #379 from haiwen/update_notes
Browse files Browse the repository at this point in the history
opt: some structures
  • Loading branch information
freeplant authored Oct 30, 2024
2 parents 91b7ad0 + 6037fb5 commit 659a1aa
Show file tree
Hide file tree
Showing 4 changed files with 67 additions and 57 deletions.
10 changes: 10 additions & 0 deletions manual/administration/seafile_fsck.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,16 @@ cd seafile-server-latest
```

!!! tip
If your Seafile server is deployed by [Docker](../setup/setup_ce_by_docker.md), you have to run the above command **in the container**:

```sh
docker exec -it seafile bash
# after entering the container
cd /scripts
./seaf-fsck.sh [--repair|-r] [--export|-E export_path] [repo_id_1 [repo_id_2 ...]]
```

There are three modes of operation for seaf-fsck:

1. checking integrity of libraries.
Expand Down
2 changes: 1 addition & 1 deletion manual/setup/caddy.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# HTTPS and Caddy

!!! note
From Seafile 12.0, the HTTPS in deployment from Docker is handled by [***Caddy***](https://caddyserver.com/docs/). The default caddy image used of Seafile docker is [`lucaslorentz/caddy-docker-proxy:2.9`](https://github.com/lucaslorentz/caddy-docker-proxy).
From Seafile Docker 12.0, HTTPS will be handled by the [***Caddy***](https://caddyserver.com/docs/). The default caddy image used of Seafile docker is [`lucaslorentz/caddy-docker-proxy:2.9`](https://github.com/lucaslorentz/caddy-docker-proxy).

Caddy is a modern open source web server that mainly binds external traffic and internal services in [seafile docker](./overview.md). In addition to the advantages of traditional proxy components (e.g., *nginx*), Caddy also makes it easier for users to complete the acquisite and update of HTTPS certificates by providing simpler configurations.

Expand Down
110 changes: 55 additions & 55 deletions manual/setup/seafile_docker_autostart.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,72 +2,72 @@

You can use one of the following methods to start Seafile container on system bootup.

=== "`docker-compose.service`"
## Modify docker-compose.service

1. Add `docker-compose.service`
1. Add `docker-compose.service`

`vim /etc/systemd/system/docker-compose.service`
`vim /etc/systemd/system/docker-compose.service`

```
[Unit]
Description=Docker Compose Application Service
Requires=docker.service
After=docker.service
```
[Unit]
Description=Docker Compose Application Service
Requires=docker.service
After=docker.service
[Service]
Type=forking
RemainAfterExit=yes
WorkingDirectory=/opt/
ExecStart=/usr/bin/docker compose up -d
ExecStop=/usr/bin/docker compose down
TimeoutStartSec=0
[Install]
WantedBy=multi-user.target
```
[Service]
Type=forking
RemainAfterExit=yes
WorkingDirectory=/opt/
ExecStart=/usr/bin/docker compose up -d
ExecStop=/usr/bin/docker compose down
TimeoutStartSec=0
!!! note
`WorkingDirectory` is the absolute path to the `seafile-server.yml` file directory.
[Install]
WantedBy=multi-user.target
```
2. Set the `docker-compose.service` file to 644 permissions
!!! note
`WorkingDirectory` is the absolute path to the `seafile-server.yml` file directory.
```
chmod 644 /etc/systemd/system/docker-compose.service
```
2. Set the `docker-compose.service` file to 644 permissions
3. Load autostart configuration
```
chmod 644 /etc/systemd/system/docker-compose.service
```
```
systemctl daemon-reload
systemctl enable docker-compose.service
```
3. Load autostart configuration
## Modify Docker files
```
systemctl daemon-reload
systemctl enable docker-compose.service
```
Add configuration `restart: unless-stopped` for each container in [components of Seafile docker](./overview.md). Take `seafile-server.yml` for example
=== "`xxx.yml`"
```
services:
db:
image: mariadb:10.11
container_name: seafile-mysql-1
restart: unless-stopped

Add configuration `restart: unless-stopped` for each container in [components of Seafile docker](./overview.md). Take `seafile-server.yml` for example
memcached:
image: memcached:1.6.18
container_name: seafile-memcached
restart: unless-stopped

```
services:
db:
image: mariadb:10.11
container_name: seafile-mysql-1
restart: unless-stopped

memcached:
image: memcached:1.6.18
container_name: seafile-memcached
restart: unless-stopped

elasticsearch:
image: elasticsearch:8.6.2
container_name: seafile-elasticsearch
restart: unless-stopped

seafile:
image: docker.seadrive.org/seafileltd/seafile-pro-mc:12.0-latest
container_name: seafile
restart: unless-stopped
```
elasticsearch:
image: elasticsearch:8.6.2
container_name: seafile-elasticsearch
restart: unless-stopped

seafile:
image: docker.seadrive.org/seafileltd/seafile-pro-mc:12.0-latest
container_name: seafile
restart: unless-stopped
```
!!! tip
Add `restart: unless-stopped`, and the Seafile container will automatically start when Docker starts. If the Seafile container does not exist (execute docker compose down), the container will not start automatically.
!!! tip
Add `restart: unless-stopped`, and the Seafile container will automatically start when Docker starts. If the Seafile container does not exist (execute docker compose down), the container will not start automatically.
2 changes: 1 addition & 1 deletion manual/setup/setup_ce_by_docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Use the [official installation guide for your OS to install Docker](https://docs

### Download and modify `.env`

!!! tip "From Seafile Docker 12.0, we use `.env`, `seafile-server.yml` and `caddy.yml` files for configuration"
From Seafile Docker 12.0, we use `.env`, `seafile-server.yml` and `caddy.yml` files for configuration

```bash
mkdir /opt/seafile
Expand Down

0 comments on commit 659a1aa

Please sign in to comment.