
podshumok/seafileFirst, you need to run mariadb or mysql image:
shelldocker run \ --name seafile-mariadb \ -v /$SOME_ABS_PATH/maria-seafile:/var/lib/mysql \ -e MYSQL_ROOT_PASSWORD=thisisabsolutlyinsecure \ -e MYSQL_USER=seafile \ -e MYSQL_PASSWORD=everybodyknowsthat \ -d mariadb:latest
shelldocker run \ --name seafile \ -v /$SOME_ABS_PATH/seafile-data:/seafile-data/ \ -p 80:8000 -p 8082:8082 -p 8080:8080 -p ***:*** -p ***:*** \ --link seafile-mariadb:db \ -e SITE_BASE=[***] \ -d podshumok/seafile
Run this image with -e SEAFILE_FASTCGI_HOST=0.0.0.0:
shelldocker run \ --name seafile \ -v /$SOME_ABS_PATH/seafile-data:/seafile-data/ \ -p ***:*** -p ***:*** \ --link seafile-mariadb:db \ -e SITE_BASE=[***] \ -e SEAFILE_FASTCGI_HOST=0.0.0.0 \ -d podshumok/seafile
Create /$SOME_ABS_PATH/conf.d/default.conf (nginx configuration file):
shellmkdir -p /$SOME_ABS_PATH/conf.d wget [***] \ -O /$SOME_ABS_PATH/conf.d/default.conf
Run nginx image:
shelldocker run \ --name seafile-nginx \ -p 80:80 \ --link seafile:seafile \ -v /$SOME_ABS_PATH/conf.d:/etc/nginx/conf.d \ -v /$SOME_ABS_PATH/nginxlog:/var/log/nginx \ -v /$SOME_EMPTY_DIR:/etc/nginx/sites-enabled \ -v /$SOME_EMPTY_DIR:/etc/nginx/certs \ -v /$SOME_EMPTY_DIR:/var/www/html \ -d nginx
Create project tree:
seafile/ |--- conf.d/ |----|--- default.conf # nginx configuration file |----ssl/ # (optional) |----|--- seafile.crt # your cacert.pem |----|--- seafile.key # your privkey.pem |--- data/ |--- docker-compose.yml
Template for conf.d/default.conf is here.
If you need HTTPS replace listen 80; with listen 443 ssl; and add ssl_certificate and ssl_certificate_key e.g.:
nginxserver { listen 443 ssl; ssl_certificate certs/seafile.crt; ssl_certificate_key certs/seafile.key; ...
docker-compose.yml sketch:
yamlmariadb: image: mariadb:latest volumes: - ./data/maria:/var/lib/mysql - ./data/log/maria:/var/log/mysql environment: - MYSQL_ROOT_PASSWORD=pleasechangeitorelse - MYSQL_USER=seafile - MYSQL_PASSWORD=thisoneshouldbechangedtoo seafile: image: podshumok/seafile volumes: - ./data/seafile:/seafile-data/ - ./data/log/seafile:/var/log/seafile links: - mariadb:db environment: # replace http:// with https:// for SSL configuration - SITE_BASE=[***] - SEAFILE_FASTCGI_HOST=0.0.0.0 nginx: image: nginx ports: - "443:443" links: - seafile volumes: - ./conf.d:/etc/nginx/conf.d:ro - ./ssl:/etc/nginx/certs:ro - ./data/log/nginx:/var/log/nginx - /tmp/empty:/etc/nginx/sites-enabled:ro - /tmp/empty:/var/www/html:ro
Now just run docker-compose up in the project root.
MYSQL_HOST - default: db comes from --link some-mysql:dbMYSQL_USER - default comes from corresponding variable from linked machineMYSQL_PASSWORD - default comes from corresponding variable from linked machineMYSQL_ROOT - default comes from corresponding variable from linked machine, if it is not set no databases or roles will be createdMYSQL_ROOT_PASSWORD - default comes from corresponding variable from linked machineADMIN_EMAIL - Admin email (login) for all services (the default is *** - change it!)ADMIN_PASSWORD - Admin password (the default is youcannotguessit - change it!)QUOTA - default: 2 - user quota in GB, integer onlyKEEP_DAYS - days to keep historyMAX_UPLOAD - maximum upload file sizeMAX_DOWNLOAD_DIR - maximum download directory sizeMEMCACHE_HOST - enable memcache at this host for cache (just --link some-memcached:memcache)MEMCACHE_PORT - default: ***EMAIL_HOST - default: smtp.gmail.com, SMPT server for email sendingEMAIL_PORT - default: 587EMAIL_USE_TLS - default: True - use TLS for SMPTEMAIL_HOST_USER - login to $EMAIL_HOST with this userEMAIL_HOST_PASSWORD - enable email sending, use this password to login to $EMAIL_HOSTCLOUD_MODE - default: False - enable cloud mode and hide Organization tabENABLE_SIGNUP - deafult: False - enable registration on webTIME_ZONE - default: UTCSITE_BASE - default: [***] - set this to seahub website's URL. This URL is contained in email notificationsSITE_NAME - default: example.com - set this to your website's name. This is contained in email notificationsSITE_TITLE - default: Seafile - set seahub website's titleSITE_ROOT - default: / - if you don't want to run seahub website on your site's root path, set this option to your preferred path, e.g. setting it to /seahub/ would run seahub on [***]SERVICE_BASE - default: $SITE_BASESERVICE_URL - default: $SITE_BASE/ if $SEAFILE_FASTCGI_HOST is not set, $SITE_BASE/seafhttp otherwiseACTIVATE_AFTER_REGISTRATION - default: True - activate user when registration complete. Default is True, if set to False, new users need to be activated by admin in admin panel.SEAFILE_FASTCGI_HOST - default: not set - serve FastCGI for Seahub on $SEAFILE_FASTCGI_HOST:8000 for reverse proxyWEBDAV_FASTCGI - default: false if $SEAFILE_FASTCGI_HOST is not set, true otherwise - serve FastCGI for webdav on port 8080 for reverse proxyWEBDAV_SHARE_NAME - default: / if $WEBDAV_FASTCGI equals false or is not set, /seafdav otherwise





manifest unknown 错误
TLS 证书验证失败
DNS 解析超时
410 错误:版本过低
402 错误:流量耗尽
身份认证失败错误
429 限流错误
凭证保存错误
来自真实用户的反馈,见证轩辕镜像的优质服务