Skip to content
This repository was archived by the owner on Dec 14, 2025. It is now read-only.

Commit 63b9ee2

Browse files
committed
0 parents  commit 63b9ee2

5 files changed

Lines changed: 399 additions & 0 deletions

File tree

.github/workflows/main.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
on: [push]
2+
jobs:
3+
build:
4+
runs-on: ubuntu-latest
5+
steps:
6+
- uses: docker/setup-qemu-action@v3
7+
- uses: docker/setup-buildx-action@v3
8+
- uses: docker/login-action@v3
9+
with:
10+
username: ${{ secrets.DOCKERHUB_USERNAME }}
11+
password: ${{ secrets.DOCKERHUB_TOKEN }}
12+
- uses: docker/build-push-action@v4
13+
with:
14+
push: true
15+
platforms: linux/amd64,linux/arm64
16+
file: ./Dockerfile
17+
tags: sstc/seaf-cli:latest
18+
- uses: actions/checkout@v4
19+
- uses: christian-korneck/update-container-description-action@v1
20+
env:
21+
DOCKER_USER: ${{ secrets.DOCKERHUB_USERNAME }}
22+
DOCKER_PASS: ${{ secrets.DOCKERHUB_PASSWORD }}
23+
with:
24+
destination_container_repo: sstc/seaf-cli
25+
short_description: https://github.com/${{ github.repository }}
26+
- uses: up9cloud/action-notify@master
27+
if: cancelled() == false
28+
env:
29+
GITHUB_JOB_STATUS: ${{ job.status }}
30+
TELEGRAM_BOT_TOKEN: ${{secrets.TELEGRAM_BOT_TOKEN}}
31+
TELEGRAM_CHAT_ID: ${{secrets.TELEGRAM_CHAT_ID}}

Dockerfile

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM debian:12-slim
2+
3+
ENV PYTHONUNBUFFERED=1
4+
5+
RUN set -ex; \
6+
apt update; \
7+
apt install \
8+
--no-install-recommends \
9+
-y \
10+
seafile-cli \
11+
oathtool \
12+
ca-certificates \
13+
gnupg;
14+
15+
COPY --chmod=755 src/entrypoint.py /entrypoint.py
16+
17+
VOLUME /seafile-client
18+
WORKDIR /seafile-client
19+
ENTRYPOINT ["/entrypoint.py"]

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025-Present https://github.com/up9cloud
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# docker-rsync
2+
3+
[![Build workflow](https://github.com/docker-sstc/docker-seaf-cli/actions/workflows/main.yml/badge.svg)](https://github.com/docker-sstc/docker-seaf-cli/actions)
4+
[![Docker pulls](https://img.shields.io/docker/pulls/sstc/seaf-cli.svg)](https://hub.docker.com/r/sstc/seaf-cli)
5+
6+
## Usage
7+
8+
```sh
9+
mkdir -p ~/seafile-client
10+
nano ~/seafile-client/config.json
11+
# {
12+
# "debug": false, // it will print commands
13+
# "username": null, // required
14+
# "password": null, // required
15+
# "server_url": "", // required, if the server on the same host, try --net=host and set it to http://0.0.0.0:<port> instead
16+
# "totp_secret": null,
17+
# "seafile": {
18+
# "disable_verify_certificate": false,
19+
# "download_limit": null,
20+
# "upload_limit": null
21+
# },
22+
# "dirs": [
23+
# {
24+
# "uuid": "...",
25+
# "path": "/app/sync_me", // path in container
26+
# "password": null
27+
# }
28+
# ]
29+
# }
30+
docker run -d \
31+
--name seaf-cli \
32+
-v ~/seafile-client:/seafile-client \
33+
-v ~/sync_me:/app/sync_me \
34+
sstc/seaf-cli
35+
36+
# server on same host, could try
37+
docker run -d \
38+
--name seaf-cli \
39+
--net=host \
40+
-v ~/seafile-client:/seafile-client \
41+
-v ~/sync_me:/app/sync_me \
42+
sstc/seaf-cli
43+
```
44+
45+
Following attributes can be override by ENV
46+
47+
```conf
48+
DEBUG=1
49+
USERNAME=username
50+
PASSWORD=password
51+
SERVER_URL=
52+
TOTP_SECRET=
53+
SEAFILE_DISABLE_VERIFY_CERTIFICATE=1
54+
SEAFILE_DOWNLOAD_LIMIT=1000000
55+
SEAFILE_UPLOAD_LIMIT=1000000
56+
```
57+
58+
## Q&A
59+
60+
### urllib.error.HTTPError: HTTP Error 400: Bad Request
61+
62+
Possible issues
63+
64+
- Not enable 2fa, but set totp_secret
65+
- totp_secret is wrong, forgot updating when reenable 2fa
66+
67+
try `docker exec -it seaf-cli /bin/bash` and make sure the command (e.q. `seaf-cli list-remote ...`) works
68+
69+
## License
70+
71+
[MIT](https://choosealicense.com/licenses/mit/)

0 commit comments

Comments
 (0)