forked from ONLYOFFICE/server
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/ZCS 10534 #1
Open
sreejan-chowdhury
wants to merge
3
commits into
Zimbra:zimbra9/onlyoffice
Choose a base branch
from
sreejan-chowdhury:feature/ZCS-10534
base: zimbra9/onlyoffice
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 2 commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
df31f2d
feature/ZCS-10534 : Scripts to install rabbitmq, start and stop docse…
sreejan-chowdhury 944f59f
feature/ZCS-10534 : adding missing config in default.json
sreejan-chowdhury 1a223d3
removing unwanted scripts, adding jq binary, changing config to shell
sreejan-chowdhury File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"appenders": { | ||
"default": { | ||
"type": "file", | ||
"filename": "../onlyoffice.log", | ||
"layout": { | ||
"type": "pattern", | ||
"pattern": "[%d] [%p] %c - %.10000m" | ||
} | ||
} | ||
}, | ||
"categories": { | ||
"default": { "appenders": [ "default" ], "level": "WARN" } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
{ | ||
"log": { | ||
"filePath": "../documentserver/server/Common/config/log4js/logconfig.json" | ||
}, | ||
"storage": { | ||
"fs": { | ||
"folderPath": "../documentserver/App_Data/cache/files" | ||
} | ||
}, | ||
"services": { | ||
"CoAuthoring": { | ||
"server": { | ||
"static_content": { | ||
"/fonts": { | ||
"path": "../documentserver/fonts", | ||
"options": {"maxAge": "7d"} | ||
}, | ||
"/sdkjs": { | ||
"path": "../documentserver/sdkjs", | ||
"options": {"maxAge": "7d"} | ||
}, | ||
"/web-apps": { | ||
"path": "../documentserver/web-apps", | ||
"options": {"maxAge": "7d"} | ||
}, | ||
"/sdkjs-plugins": { | ||
"path": "../documentserver/sdkjs-plugins", | ||
"options": {"maxAge": "7d"} | ||
}, | ||
"/App_Data": { | ||
"path": "../documentserver/App_Data", | ||
"options": {"maxAge": "7d"} | ||
} | ||
} | ||
}, | ||
"utils": { | ||
"utils_common_fontdir": "/usr/share/fonts" | ||
}, | ||
"request-filtering-agent" : { | ||
"allowPrivateIPAddress": true, | ||
"allowMetaIPAddress": true | ||
}, | ||
"sockjs": { | ||
"sockjs_url": "../documentserver/web-apps/vendor/sockjs/sockjs.min.js" | ||
} | ||
} | ||
}, | ||
"license": { | ||
"license_file": "./../documentserver/license.lic", | ||
"warning_limit_percents": 70, | ||
"packageType": 0 | ||
}, | ||
"FileConverter": { | ||
"converter": { | ||
"fontDir": "/usr/share/fonts", | ||
"presentationThemesDir": "../documentserver/sdkjs/slide/themes", | ||
"x2tPath": "../documentserver/server/FileConverter/bin/x2t", | ||
"docbuilderPath": "../documentserver/server/FileConverter/bin/docbuilder", | ||
"docbuilderAllFontsPath": "../documentserver/App_Data/docbuilder/AllFonts.js" | ||
} | ||
}, | ||
"FileStorage": { | ||
"directory": "../documentserver/App_Data" | ||
}, | ||
"SpellChecker": { | ||
"server": { | ||
"dictDir": "../documentserver/server/SpellChecker/dictionaries" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import json | ||
import os.path | ||
import os | ||
import sys | ||
|
||
def check_services_running(): | ||
with open(processid_file_path, "r") as f: | ||
data = json.load(f) | ||
|
||
if(data["docservice"] > 0 and check_pid(data["docservice"])): | ||
sys.exit("Error : docservice running with pid (" + str(data["docservice"]) + ") ") | ||
if(data["spellchecker"] > 0 and check_pid(data["spellchecker"])): | ||
sys.exit("Error : spellchecker running with pid (" + str(data["spellchecker"]) + ") ") | ||
if(data["converter"] > 0 and check_pid(data["converter"])): | ||
sys.exit("Error : converter running with pid (" + str(data["converter"]) + ") ") | ||
|
||
def check_docservice_running(): | ||
with open(processid_file_path, "r") as f: | ||
data = json.load(f) | ||
|
||
if(data["docservice"] > 0 and check_pid(data["docservice"])): | ||
sys.exit("Error : docservice running with pid (" + str(data["docservice"]) + ") ") | ||
|
||
def check_spellchecker_running(): | ||
with open(processid_file_path, "r") as f: | ||
data = json.load(f) | ||
|
||
if(data["spellchecker"] > 0 and check_pid(data["spellchecker"])): | ||
sys.exit("Error : spellchecker running with pid (" + str(data["spellchecker"]) + ") ") | ||
|
||
def check_converter_running(): | ||
with open(processid_file_path, "r") as f: | ||
data = json.load(f) | ||
|
||
if(data["converter"] > 0 and check_pid(data["converter"])): | ||
sys.exit("Error : converter running with pid (" + str(data["converter"]) + ") ") | ||
|
||
def check_pid(pid): | ||
try: | ||
os.kill(pid, 0) | ||
except OSError: | ||
return False | ||
else: | ||
return True | ||
|
||
def update_processid(docservice_process_id, spellchecker_process_id, converter_process_id): | ||
with open(processid_file_path, "r") as f: | ||
data = json.load(f) | ||
|
||
if(docservice_process_id > 0): | ||
data["docservice"] = docservice_process_id | ||
if(spellchecker_process_id > 0): | ||
data["spellchecker"] = spellchecker_process_id | ||
if(converter_process_id > 0): | ||
data["converter"] = converter_process_id | ||
|
||
with open(processid_file_path, "w") as jsonFile: | ||
json.dump(data, jsonFile, indent=4) | ||
|
||
with open(processid_file_path, "r") as f: | ||
dataupdated = json.load(f) | ||
#print("Process IDS docservice, spellchecker, converter :: "+str(dataupdated)) | ||
processid_file_path = "process_id.json" |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you intend to remove this commented line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left it by mistake. Thanks