Skip to content

Commit

Permalink
improve onlyoffice
Browse files Browse the repository at this point in the history
  • Loading branch information
chendelin1982 authored Jan 12, 2024
1 parent 93a50b5 commit 702d113
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 16 deletions.
3 changes: 2 additions & 1 deletion apps/onlyoffice/.env
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ W9_URL=appname.example.com
W9_DB_EXPOSE="mysql"
W9_DB_VERSION=8.0
W9_NETWORK=websoft9
#### --------------------------------------------------------------------------------------- ####
#### --------------------------------------------------------------------------------------- ####

7 changes: 2 additions & 5 deletions apps/onlyoffice/Notes.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
## About
# About

This repository is forked from ONLYOFFICE/Docker-CommunityServer, we have the following modifications are provided

* replace README.md
* add README-zh.md, CHANGELOG.md, Note.md, License.md, docker-compose.yml,.env, src, .github folder
当前删除了 ES, onlyoffice-docs, onlyoffice-mailserver,目前启动失败
34 changes: 30 additions & 4 deletions apps/onlyoffice/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# compose: https://github.com/ONLYOFFICE/Docker-CommunityServer/blob/master/docker-compose.workspace.yml
# image: https://hub.docker.com/r/onlyoffice/communityserver
# docs: https://github.com/ONLYOFFICE/Docker-CommunityServer
# Not use: ES, onlyoffice-docs, onlyoffice-mailserver
# Websoft9 modification: delete ES, onlyoffice-docs, onlyoffice-mailserver

version: '3.8'
services:
Expand All @@ -19,6 +20,8 @@ services:
- MYSQL_SERVER_HOST=${W9_ID}-mysql
- MYSQL_SERVER_USER=onlyoffice
- MYSQL_SERVER_PASS=${W9_POWER_PASSWORD}
- ELASTICSEARCH_SERVER_HOST=${W9_ID}-elasticsearch
- ELASTICSEARCH_SERVER_HTTPPORT=9200
ports:
- ${W9_HTTP_PORT_SET}:80
#- 5222:5222 # IM port
Expand All @@ -45,17 +48,39 @@ services:
- controlpanel_data:/var/www/onlyoffice/Data
- controlpanel_log:/var/log/onlyoffice

onlyoffice-elasticsearch:
image: onlyoffice/elasticsearch:7.16.3
container_name: ${W9_ID}-elasticsearch
restart: unless-stopped
environment:
- discovery.type=single-node
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms1g -Xmx1g -Dlog4j2.formatMsgNoLookups=true"
- "indices.fielddata.cache.size=30%"
- "indices.memory.index_buffer_size=30%"
- "ingest.geoip.downloader.enabled=false"
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65535
hard: 65535
volumes:
- es_data:/usr/share/elasticsearch/data
expose:
- "9200"
- "9300"

onlyoffice-mysql-server:
container_name: ${W9_ID}-mysql
image: mysql:$W9_DB_VERSION
command: --default-authentication-plugin=mysql_native_password --collation-server=utf8_general_ci
environment:
- MYSQL_DATABASE=onlyoffice
- MYSQL_USER=onlyoffice
- MYSQL_PASSWORD=${W9_POWER_PASSWORD}
- MYSQL_ROOT_PASSWORD=${W9_POWER_PASSWORD}
stdin_open: true
tty: true
restart: unless-stopped
volumes:
- ./src/mysql/conf.d:/etc/mysql/conf.d
- ./src/mysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
Expand All @@ -67,6 +92,7 @@ volumes:
controlpanel_data:
controlpanel_log:
mysql_data:
es_data:

networks:
default:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CREATE DATABASE IF NOT EXISTS onlyoffice CHARACTER SET "utf8" COLLATE "utf8_general_ci";
CREATE USER IF NOT EXISTS 'onlyoffice'@'%' IDENTIFIED BY '$MYSQL_PASSWORD';
GRANT ALL PRIVILEGES ON onlyoffice.* TO 'onlyoffice'@'%';
FLUSH PRIVILEGES;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
GRANT ALL PRIVILEGES ON *.* TO 'onlyoffice_user'@'%';

FLUSH PRIVILEGES;
2 changes: 1 addition & 1 deletion apps/onlyoffice/variables.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "onlyoffice",
"trademark": "ONLYOFFICE",
"trademark": "ONLYOFFICE Workspace",
"release": true,
"fork_url": "https://github.com/ONLYOFFICE/Docker-CommunityServer.git",
"edition": [
Expand Down
2 changes: 1 addition & 1 deletion apps/onlyofficedocs/variables.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "onlyofficedocs",
"trademark": "ONLYOFFICEDocs",
"trademark": "ONLYOFFICE Docs",
"release": true,
"fork_url": "https://github.com/ONLYOFFICE/Docker-DocumentServer",
"edition": [
Expand Down

0 comments on commit 702d113

Please sign in to comment.