Compare commits
10 Commits
1d74180324
...
55fc00480d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
55fc00480d | ||
|
|
6beea74a9f | ||
|
|
cafe2270d8 | ||
|
|
12ba39042f | ||
|
|
bb443ab523 | ||
|
|
0e667663a1 | ||
|
|
42a151980e | ||
|
|
38f0522e8f | ||
|
|
0f2af434a3 | ||
|
|
223299db61 |
@@ -29,8 +29,14 @@ ApiDocument
|
|||||||
ApiDrawing
|
ApiDrawing
|
||||||
ApiFormRoles
|
ApiFormRoles
|
||||||
ApiFreezePanes
|
ApiFreezePanes
|
||||||
|
ApiGeometry
|
||||||
ApiNotesPage
|
ApiNotesPage
|
||||||
ApiParagraph
|
ApiParagraph
|
||||||
|
ApiPath
|
||||||
|
ApiPathCommand
|
||||||
|
ApiPivotField
|
||||||
|
ApiPivotFilters
|
||||||
|
ApiPivotItem
|
||||||
ApiRange
|
ApiRange
|
||||||
ApiSlide
|
ApiSlide
|
||||||
ApiTable
|
ApiTable
|
||||||
@@ -56,6 +62,7 @@ autocomplete
|
|||||||
Autocompletion
|
Autocompletion
|
||||||
autocorrect
|
autocorrect
|
||||||
AutoCorrect
|
AutoCorrect
|
||||||
|
autocorrecting
|
||||||
autocorrection
|
autocorrection
|
||||||
autofill
|
autofill
|
||||||
autofilter
|
autofilter
|
||||||
@@ -64,6 +71,8 @@ autofilters
|
|||||||
autofilling
|
autofilling
|
||||||
autofit
|
autofit
|
||||||
Autofit
|
Autofit
|
||||||
|
AutoFit
|
||||||
|
autofitting
|
||||||
AutoFormat
|
AutoFormat
|
||||||
autohyphenation
|
autohyphenation
|
||||||
autonumbering
|
autonumbering
|
||||||
@@ -114,6 +123,7 @@ changesError
|
|||||||
ChartSheetSubstream
|
ChartSheetSubstream
|
||||||
checkbox
|
checkbox
|
||||||
CheckBox
|
CheckBox
|
||||||
|
checkboxes
|
||||||
checkBoxPr
|
checkBoxPr
|
||||||
checkHealth
|
checkHealth
|
||||||
CHIDIST
|
CHIDIST
|
||||||
@@ -134,6 +144,8 @@ Cmd
|
|||||||
CNumberingLvlLegacy
|
CNumberingLvlLegacy
|
||||||
coedit
|
coedit
|
||||||
CollaborationEditing
|
CollaborationEditing
|
||||||
|
columnOffset
|
||||||
|
columnSize
|
||||||
ColumnWidth
|
ColumnWidth
|
||||||
COMBINA
|
COMBINA
|
||||||
CommandService
|
CommandService
|
||||||
@@ -191,6 +203,7 @@ Danmark
|
|||||||
Dansk
|
Dansk
|
||||||
dataset
|
dataset
|
||||||
dataBinding
|
dataBinding
|
||||||
|
dataField
|
||||||
DatePicker
|
DatePicker
|
||||||
datePickerPr
|
datePickerPr
|
||||||
DAVERAGE
|
DAVERAGE
|
||||||
@@ -199,16 +212,20 @@ DCOUNT
|
|||||||
DCOUNTA
|
DCOUNTA
|
||||||
de
|
de
|
||||||
Decryptor
|
Decryptor
|
||||||
|
DeepL
|
||||||
delegateRole
|
delegateRole
|
||||||
deleteForgotten
|
deleteForgotten
|
||||||
|
denyEditingRights
|
||||||
Deprecations
|
Deprecations
|
||||||
DesktopEditors
|
DesktopEditors
|
||||||
Deutsch
|
Deutsch
|
||||||
|
dev
|
||||||
DGET
|
DGET
|
||||||
dialogs
|
dialogs
|
||||||
dir
|
dir
|
||||||
DirTree
|
DirTree
|
||||||
djvu
|
djvu
|
||||||
|
DjVu
|
||||||
DjVU
|
DjVU
|
||||||
DK
|
DK
|
||||||
DMAX
|
DMAX
|
||||||
@@ -216,8 +233,10 @@ DMS
|
|||||||
dns
|
dns
|
||||||
DocFormat
|
DocFormat
|
||||||
docId
|
docId
|
||||||
|
DocServer
|
||||||
docservice
|
docservice
|
||||||
DocSpace
|
DocSpace
|
||||||
|
DOCT
|
||||||
DocumentBuilder
|
DocumentBuilder
|
||||||
DocumentEditor
|
DocumentEditor
|
||||||
documentserver
|
documentserver
|
||||||
@@ -275,6 +294,7 @@ fillForms
|
|||||||
FINV
|
FINV
|
||||||
firefox
|
firefox
|
||||||
flv
|
flv
|
||||||
|
fmla
|
||||||
FormattedDiskPageCHPX
|
FormattedDiskPageCHPX
|
||||||
Fn
|
Fn
|
||||||
fodp
|
fodp
|
||||||
@@ -310,6 +330,7 @@ gcc
|
|||||||
GenerateGuid
|
GenerateGuid
|
||||||
GetAdress
|
GetAdress
|
||||||
GetAllCaptionParagraphs
|
GetAllCaptionParagraphs
|
||||||
|
GetAllContentControls
|
||||||
GetAllHeadingParagraphs
|
GetAllHeadingParagraphs
|
||||||
GetAllNumberedParagraphs
|
GetAllNumberedParagraphs
|
||||||
GetAllTables
|
GetAllTables
|
||||||
@@ -369,12 +390,14 @@ gziped
|
|||||||
hAnsi
|
hAnsi
|
||||||
healthcheck
|
healthcheck
|
||||||
healthCheck
|
healthCheck
|
||||||
|
HEIF
|
||||||
hideContentControlTrack
|
hideContentControlTrack
|
||||||
hideRightMenu
|
hideRightMenu
|
||||||
HiDPI
|
HiDPI
|
||||||
HLOOKUP
|
HLOOKUP
|
||||||
hotkey
|
hotkey
|
||||||
hotkeys
|
hotkeys
|
||||||
|
hR
|
||||||
HTM
|
HTM
|
||||||
html
|
html
|
||||||
htmlutils
|
htmlutils
|
||||||
@@ -383,6 +406,7 @@ HSTACK
|
|||||||
hy
|
hy
|
||||||
HYPGEOM
|
HYPGEOM
|
||||||
HWP
|
HWP
|
||||||
|
HWPML
|
||||||
HWPX
|
HWPX
|
||||||
icu
|
icu
|
||||||
ie
|
ie
|
||||||
@@ -439,12 +463,16 @@ json
|
|||||||
jsonwebtocken
|
jsonwebtocken
|
||||||
jwt
|
jwt
|
||||||
JWT
|
JWT
|
||||||
|
keepContent
|
||||||
|
KMS
|
||||||
korean
|
korean
|
||||||
lang
|
lang
|
||||||
|
LanguageTool
|
||||||
LaTeX
|
LaTeX
|
||||||
Latn
|
Latn
|
||||||
LeftMargin
|
LeftMargin
|
||||||
leftMenu
|
leftMenu
|
||||||
|
libc
|
||||||
libcurl
|
libcurl
|
||||||
librabbitmq
|
librabbitmq
|
||||||
libs
|
libs
|
||||||
@@ -470,10 +498,12 @@ LTS
|
|||||||
macOS
|
macOS
|
||||||
MacOs
|
MacOs
|
||||||
mariadb
|
mariadb
|
||||||
|
MathML
|
||||||
mathType
|
mathType
|
||||||
MathType
|
MathType
|
||||||
maxChangesSize
|
maxChangesSize
|
||||||
MAXIFS
|
MAXIFS
|
||||||
|
md
|
||||||
Mendeley
|
Mendeley
|
||||||
MergeArea
|
MergeArea
|
||||||
metadata
|
metadata
|
||||||
@@ -497,6 +527,7 @@ MULT
|
|||||||
multi
|
multi
|
||||||
multichart
|
multichart
|
||||||
multicomments
|
multicomments
|
||||||
|
Multiline
|
||||||
multiselect
|
multiselect
|
||||||
multitenancy
|
multitenancy
|
||||||
mysql
|
mysql
|
||||||
@@ -547,13 +578,17 @@ oLastPrinted
|
|||||||
OLEObjectData
|
OLEObjectData
|
||||||
oModified
|
oModified
|
||||||
onChangeContentControl
|
onChangeContentControl
|
||||||
|
onBlurAnnotation
|
||||||
|
onClickAnnotation
|
||||||
onDocumentContentReady
|
onDocumentContentReady
|
||||||
onDocumentStateChange
|
onDocumentStateChange
|
||||||
|
onFocusAnnotation
|
||||||
onInsertOleObjects
|
onInsertOleObjects
|
||||||
onlyoffice
|
onlyoffice
|
||||||
ONLYOFFICE
|
ONLYOFFICE
|
||||||
OnlySignatures
|
OnlySignatures
|
||||||
onOutdatedVersion
|
onOutdatedVersion
|
||||||
|
onParagraphText
|
||||||
onRequestCompareFile
|
onRequestCompareFile
|
||||||
onRequestEditRights
|
onRequestEditRights
|
||||||
onRequestInsertImage
|
onRequestInsertImage
|
||||||
@@ -585,6 +620,8 @@ nPage
|
|||||||
pageDown
|
pageDown
|
||||||
ParaDrawing
|
ParaDrawing
|
||||||
Paragarph
|
Paragarph
|
||||||
|
paragraphId
|
||||||
|
paraId
|
||||||
param
|
param
|
||||||
params
|
params
|
||||||
passsword
|
passsword
|
||||||
@@ -641,6 +678,7 @@ queuedelayed
|
|||||||
rabbitmq
|
rabbitmq
|
||||||
RabbitMQ
|
RabbitMQ
|
||||||
RANDARRAY
|
RANDARRAY
|
||||||
|
rangeId
|
||||||
rastr
|
rastr
|
||||||
ReadEmrTextBase
|
ReadEmrTextBase
|
||||||
ReadFromBinary
|
ReadFromBinary
|
||||||
@@ -648,6 +686,7 @@ ReadStandartEncryptionInfo
|
|||||||
Realtime
|
Realtime
|
||||||
rebranding
|
rebranding
|
||||||
Rebranding
|
Rebranding
|
||||||
|
recalcId
|
||||||
reconnection
|
reconnection
|
||||||
rect
|
rect
|
||||||
redis
|
redis
|
||||||
@@ -773,6 +812,7 @@ sslEnabled
|
|||||||
sStatus
|
sStatus
|
||||||
sSubject
|
sSubject
|
||||||
standardView
|
standardView
|
||||||
|
stAng
|
||||||
startRPC
|
startRPC
|
||||||
startup
|
startup
|
||||||
statsd
|
statsd
|
||||||
@@ -787,6 +827,7 @@ storages
|
|||||||
STW
|
STW
|
||||||
submitForm
|
submitForm
|
||||||
substring
|
substring
|
||||||
|
suggestFeature
|
||||||
SUMIFS
|
SUMIFS
|
||||||
SUMPRODUCT
|
SUMPRODUCT
|
||||||
supervisord
|
supervisord
|
||||||
@@ -798,6 +839,7 @@ sVersion
|
|||||||
svg
|
svg
|
||||||
SVG
|
SVG
|
||||||
Svizzera
|
Svizzera
|
||||||
|
swAng
|
||||||
SXC
|
SXC
|
||||||
SXI
|
SXI
|
||||||
SXV
|
SXV
|
||||||
@@ -821,6 +863,7 @@ TOC
|
|||||||
TOCOL
|
TOCOL
|
||||||
toLocaleString
|
toLocaleString
|
||||||
TOROW
|
TOROW
|
||||||
|
toolbarHideFileName
|
||||||
toolbarNoTabs
|
toolbarNoTabs
|
||||||
tooltip
|
tooltip
|
||||||
tooltips
|
tooltips
|
||||||
@@ -833,6 +876,7 @@ ttf
|
|||||||
TW
|
TW
|
||||||
txPr
|
txPr
|
||||||
txt
|
txt
|
||||||
|
Typograf
|
||||||
ubuntu
|
ubuntu
|
||||||
UI
|
UI
|
||||||
unary
|
unary
|
||||||
@@ -854,6 +898,7 @@ urls
|
|||||||
useDirectStorageUrls
|
useDirectStorageUrls
|
||||||
UsedRange
|
UsedRange
|
||||||
useradd
|
useradd
|
||||||
|
UserCanOnlyComment
|
||||||
UserCount
|
UserCount
|
||||||
userId
|
userId
|
||||||
useridoriginal
|
useridoriginal
|
||||||
@@ -870,13 +915,17 @@ VLOOKUP
|
|||||||
VSD
|
VSD
|
||||||
VSDX
|
VSDX
|
||||||
VSTACK
|
VSTACK
|
||||||
|
VSTX
|
||||||
vml
|
vml
|
||||||
wav
|
wav
|
||||||
|
websocket
|
||||||
WEIBULL
|
WEIBULL
|
||||||
wget
|
wget
|
||||||
|
wholeDayFilter
|
||||||
WinSW
|
WinSW
|
||||||
WinXp
|
WinXp
|
||||||
wmf
|
wmf
|
||||||
|
woff
|
||||||
wopi
|
wopi
|
||||||
WOPI
|
WOPI
|
||||||
WOPISrc
|
WOPISrc
|
||||||
@@ -897,6 +946,7 @@ xlsb
|
|||||||
XlsFormatReader
|
XlsFormatReader
|
||||||
XLSM
|
XLSM
|
||||||
xlsx
|
xlsx
|
||||||
|
XLST
|
||||||
XLSX
|
XLSX
|
||||||
XLTX
|
XLTX
|
||||||
XMATCH
|
XMATCH
|
||||||
@@ -916,4 +966,4 @@ ZA
|
|||||||
Zb
|
Zb
|
||||||
zh
|
zh
|
||||||
Zotero
|
Zotero
|
||||||
ZTEST
|
ZTEST
|
||||||
568
CHANGELOG.md
568
CHANGELOG.md
@@ -1,5 +1,573 @@
|
|||||||
# Change log
|
# Change log
|
||||||
|
|
||||||
|
## 9.2.0
|
||||||
|
|
||||||
|
### New features
|
||||||
|
|
||||||
|
#### All Editors
|
||||||
|
|
||||||
|
* Added the ability to customize keyboard shortcuts
|
||||||
|
* Added the ability to record some executed actions as a macro in all editors,
|
||||||
|
except for PDF
|
||||||
|
|
||||||
|
#### Presentation Editor
|
||||||
|
|
||||||
|
* Implemented insertion of equations from a third-party resource
|
||||||
|
|
||||||
|
#### Forms
|
||||||
|
|
||||||
|
* Implemented the ability to select the role for which new fields
|
||||||
|
will be added
|
||||||
|
* Implemented the ability to add labels for checkboxes and radio buttons.
|
||||||
|
In the filling mode, clicking on the label works like clicking
|
||||||
|
on the checkbox itself
|
||||||
|
|
||||||
|
#### PDF Editor
|
||||||
|
|
||||||
|
* Added the ability to change color for hidden text (Redact)
|
||||||
|
* Implemented insertion of equations from a third-party resource
|
||||||
|
|
||||||
|
#### Security
|
||||||
|
|
||||||
|
* Updated Redis to versions not affected by the CVE-2025-49844 vulnerability
|
||||||
|
* Fixed the vulnerability which allows adding a named range in the protected
|
||||||
|
workbook via websocket
|
||||||
|
* Fixed the XSS vulnerability in the `denyEditingRights`
|
||||||
|
* Fixed the vulnerabilities in `linux-libc-dev` which allow escalating
|
||||||
|
privileges in the system and stealing data from hypervisor processes
|
||||||
|
(CVE-2025-38352, CVE-2025-40300)
|
||||||
|
|
||||||
|
#### Back-end
|
||||||
|
|
||||||
|
* Improved the appearance of the sidebar and added icons to the Admin Panel
|
||||||
|
|
||||||
|
#### API
|
||||||
|
|
||||||
|
* Added methods for getting and setting text for checkboxes and radio buttons
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiCheckBoxForm.prototype.SetLabel = function(label)
|
||||||
|
ApiCheckBoxForm.prototype.GetLabel = function()
|
||||||
|
```
|
||||||
|
|
||||||
|
* Added methods for working with the numerical identifier of a paragraph,
|
||||||
|
which is saved in the file
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiParagraph.prototype.GetParaId
|
||||||
|
ApiParagraph.prototype.SetParaId
|
||||||
|
```
|
||||||
|
|
||||||
|
* Added a method for deleting a form from the document with the ability
|
||||||
|
to save the content, similar to the method for Content Control
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiFormBase.prototype.Delete = function(keepContent)
|
||||||
|
```
|
||||||
|
|
||||||
|
* Added a method for getting forms
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiDocument.prototype.GetAllForms
|
||||||
|
```
|
||||||
|
|
||||||
|
* The `GetAllContentControls` method, which returns a Content Control,
|
||||||
|
no longer returns forms
|
||||||
|
* Added the `onParagraphText` event, indicating that the paragraph content
|
||||||
|
was changed, with the following json object:
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
{
|
||||||
|
"paragraphId" : paraId,
|
||||||
|
"recalcId" : recalcId,
|
||||||
|
"text" : text,
|
||||||
|
"annotations" : []
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
where annotations - an array of elements (new positions for annotations
|
||||||
|
after the previous markup)
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
{
|
||||||
|
"id" : id,
|
||||||
|
"start" : start,
|
||||||
|
"length" : length,
|
||||||
|
"name" : "grammar"
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
* Added events for working with annotations:
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
onClickAnnotation
|
||||||
|
onFocusAnnotation
|
||||||
|
onBlurAnnotation
|
||||||
|
```
|
||||||
|
|
||||||
|
They have the following parameter object describing the annotation
|
||||||
|
with which the corresponding action was performed:
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
{
|
||||||
|
"paragraphId" : paraId,
|
||||||
|
"rangeId" : [rangeId, ...],
|
||||||
|
"name" : "grammar"
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Plugins
|
||||||
|
|
||||||
|
* Added Grammar & Spelling check in the Document and Form Editors
|
||||||
|
in the AI plugin
|
||||||
|
|
||||||
|
## 9.1.0
|
||||||
|
|
||||||
|
### New features
|
||||||
|
|
||||||
|
#### All Editors
|
||||||
|
|
||||||
|
* Added external data for charts. When copying between editors, it’s possible
|
||||||
|
to select either an embedded file or a link to the source
|
||||||
|
* Added the ability to enable/disable chart elements
|
||||||
|
* Added support for the Explosion option (separating a segment of pie
|
||||||
|
and doughnut 2d charts) for opening
|
||||||
|
* Added support for the `HEIF` images
|
||||||
|
* Added the ability to configure the display of resolved/open comments
|
||||||
|
in the left panel
|
||||||
|
|
||||||
|
#### Document Editor
|
||||||
|
|
||||||
|
* Implemented support for breaking sections within block content controls
|
||||||
|
with any nesting level
|
||||||
|
* Added a full-featured chart editor. Embedded `XLSX` files are now opened
|
||||||
|
instead of loading values from the chart cache
|
||||||
|
* Added support for the `HWPML` text document format for viewing
|
||||||
|
* Added support for inserting mathematical formulas from the MathML format
|
||||||
|
|
||||||
|
#### Spreadsheet Editor
|
||||||
|
|
||||||
|
* Add a setting for a general text direction in a cell
|
||||||
|
* Added support for date filters in pivot tables
|
||||||
|
* Added some Form Controls (Check Box, Combo Box, List Box, Spin Button,
|
||||||
|
Scroll Bar, Button) for opening
|
||||||
|
* Improved the logic of formulas for mixed data types
|
||||||
|
* Reduced memory consumption during formula calculations
|
||||||
|
* Optimized calculation of the `VLOOKUP` and `XLOOKUP` formulas
|
||||||
|
* Added highlighting of active arguments when entering a formula
|
||||||
|
* Added translation of formulas into Serbian (Cyrillic), Serbian (Latin)
|
||||||
|
and Chinese (Traditional)
|
||||||
|
* Added support for inserting mathematical formulas from the MathML format
|
||||||
|
* Moved formatted table settings from the right panel to the Table Design
|
||||||
|
tab of the top toolbar. The tab appears only when we are working within
|
||||||
|
a table
|
||||||
|
* Added the ability to rename a sheet by double-clicking on its name
|
||||||
|
without opening additional windows
|
||||||
|
|
||||||
|
#### Presentation Editor
|
||||||
|
|
||||||
|
* Added a full-featured chart editor. Embedded `XLSX` files are now opened
|
||||||
|
instead of loading values from the chart cache
|
||||||
|
* Moved Master Slide settings from the Insert tab to a separate tab
|
||||||
|
of the top toolbar
|
||||||
|
|
||||||
|
#### Forms
|
||||||
|
|
||||||
|
* Improved user experience when working with fields
|
||||||
|
* Renamed the View Form and Manage Roles buttons to Preview
|
||||||
|
and Manage Recipient Roles
|
||||||
|
* Added support for inserting mathematical formulas from the MathML format
|
||||||
|
|
||||||
|
#### PDF Editor
|
||||||
|
|
||||||
|
* Added functionality for hiding confidential information - Redact
|
||||||
|
* Added new annotation types to the Comment section
|
||||||
|
* Implemented work with Smart Art
|
||||||
|
* Added support for charts
|
||||||
|
* Implemented copying and pasting graphic elements and forms
|
||||||
|
|
||||||
|
#### Security
|
||||||
|
|
||||||
|
* Fixed the XSS vulnerability when processing hyperlinks in documents
|
||||||
|
* Fixed the vulnerability which allows writing arbitrary files
|
||||||
|
to the file system when converting via x2t
|
||||||
|
* Fixed the vulnerability which allows reading arbitrary files
|
||||||
|
in the file system when converting `EPUB` via ConvertService
|
||||||
|
* Fixed the vulnerability in endpoint `info/config` which allows changing
|
||||||
|
the server configuration
|
||||||
|
|
||||||
|
#### Convert
|
||||||
|
|
||||||
|
* Added the ability to convert `PDF` and `PPTX` to `TXT` directly
|
||||||
|
|
||||||
|
#### Back-end
|
||||||
|
|
||||||
|
* Added the admin panel for viewing the server status and partially setting up
|
||||||
|
the configuration
|
||||||
|
* Added the `storage.commandOptions.s3` and `storage.commandOptions.az`
|
||||||
|
settings for customizing storage commands, for example, for enabling AWS KMS
|
||||||
|
or setting up Azure Blob Storage
|
||||||
|
* Changed the `storage.useDirectStorageUrls=false` value: DocServer now returns
|
||||||
|
internal links by default
|
||||||
|
* Added the `oracleExtraOptions.thin` setting for connecting to Oracle
|
||||||
|
in the Thick Mode using Oracle Instant Client in a cluster
|
||||||
|
* Removed the public scheme from the PostgreSQL DB. Now the administrator can
|
||||||
|
specify any scheme when creating a database and specify it in the server
|
||||||
|
configuration and the `pgPoolExtraOptions` section
|
||||||
|
* Added the `DB_SCHEMA` parameter which allows selecting a scheme in DB.
|
||||||
|
Works only for PostgreSQL and MSSQL, for other databases it is ignored
|
||||||
|
(deb, docker, rpm)
|
||||||
|
|
||||||
|
#### WOPI
|
||||||
|
|
||||||
|
* Added support for the `UserCanOnlyComment` parameter in [`CheckFileInfo`](https://api.onlyoffice.com/docs/docs-api/using-wopi/wopi-rest-api/checkfileinfo/)
|
||||||
|
for opening in the commenting mode. The behavior is similar to
|
||||||
|
`document.permissions.comment` in our API
|
||||||
|
* Added opening in the View mode with an error message if it was not possible
|
||||||
|
to set a lock on a file when opening the editor
|
||||||
|
|
||||||
|
#### API
|
||||||
|
|
||||||
|
* Added classes and methods for working with pivot table filters
|
||||||
|
|
||||||
|
`ApiPivotField`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiPivotField.prototype.GetPivotFilters()
|
||||||
|
ApiPivotField.prototype.AutoSort(order, field, property)
|
||||||
|
ApiPivotField.prototype.AutoSortField
|
||||||
|
ApiPivotField.prototype.AutoSortOrder
|
||||||
|
```
|
||||||
|
|
||||||
|
`ApiPivotFilters`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiPivotFilters.prototype.Add(filterType, dataField, value1, value2,
|
||||||
|
wholeDayFilter)
|
||||||
|
```
|
||||||
|
|
||||||
|
`ApiPivotItem`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiPivotItem.prototype.GetVisible()
|
||||||
|
ApiPivotItem.prototype.SetVisible(visible)
|
||||||
|
```
|
||||||
|
|
||||||
|
Common `ApiRange` methods
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiRange.prototype.Offset(rowOffset, columnOffset)
|
||||||
|
ApiRange.prototype.Resize(rowSize, columnSize)
|
||||||
|
ApiRange.prototype.GetRange(cell1, cell2)
|
||||||
|
ApiRange.prototype.GetEntireRow()
|
||||||
|
ApiRange.prototype.GetEntireColumn()
|
||||||
|
```
|
||||||
|
|
||||||
|
* Added classes and methods for working with shape geometry
|
||||||
|
|
||||||
|
`API`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
Api.prototype.CreateCustomGeometry()
|
||||||
|
Api.prototype.CreatePresetGeometry(preset)
|
||||||
|
ApiShape.prototype.GetGeometry
|
||||||
|
ApiShape.prototype.SetGeometry(geometry)
|
||||||
|
```
|
||||||
|
|
||||||
|
`ApiGeometry`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiGeometry.prototype.IsCustom()
|
||||||
|
ApiGeometry.prototype.GetPreset()
|
||||||
|
ApiGeometry.prototype.GetPathCount()
|
||||||
|
ApiGeometry.prototype.GetPath(index)
|
||||||
|
ApiGeometry.prototype.GetPaths()
|
||||||
|
ApiGeometry.prototype.AddPath()
|
||||||
|
ApiGeometry.prototype.GetAdjValue(name)
|
||||||
|
ApiGeometry.prototype.AddAdj(name, value)
|
||||||
|
ApiGeometry.prototype.SetAdjValue(value)
|
||||||
|
ApiGeometry.prototype.AddGuide(name, fmla, x, y, z)
|
||||||
|
ApiGeometry.prototype.SetTextRect(l, t, r, b)
|
||||||
|
ApiGeometry.prototype.AddConnectionPoint(angle, x, y)
|
||||||
|
```
|
||||||
|
|
||||||
|
`ApiPath`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiPath.prototype.GetStroke()
|
||||||
|
ApiPath.prototype.SetStroke(stroke)
|
||||||
|
ApiPath.prototype.GetFill()
|
||||||
|
ApiPath.prototype.SetFill(fill)
|
||||||
|
ApiPath.prototype.GetWidth()
|
||||||
|
ApiPath.prototype.SetWidth(width)
|
||||||
|
ApiPath.prototype.GetHeight()
|
||||||
|
ApiPath.prototype.SetHeight(height)
|
||||||
|
ApiPath.prototype.GetCommands()
|
||||||
|
ApiPath.prototype.GetCommandCount()
|
||||||
|
ApiPath.prototype.GetCommand(index)
|
||||||
|
ApiPath.prototype.MoveTo(x, y)
|
||||||
|
ApiPath.prototype.LineTo(x, y)
|
||||||
|
ApiPath.prototype.CubicBezTo(x1, y1, x2, y2, x3, y3)
|
||||||
|
ApiPath.prototype.QuadBezTo(x1, y1, x2, y2)
|
||||||
|
ApiPath.prototype.ArcTo(wR, hR, stAng, swAng)
|
||||||
|
ApiPath.prototype.Close()
|
||||||
|
```
|
||||||
|
|
||||||
|
`ApiPathCommand`
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
ApiPathCommand.prototype.GetType()
|
||||||
|
ApiPathCommand.prototype.GetX()
|
||||||
|
ApiPathCommand.prototype.GetY()
|
||||||
|
ApiPathCommand.prototype.GetX0()
|
||||||
|
ApiPathCommand.prototype.GetY0()
|
||||||
|
ApiPathCommand.prototype.GetX1()
|
||||||
|
ApiPathCommand.prototype.GetY1()
|
||||||
|
ApiPathCommand.prototype.GetX2()
|
||||||
|
ApiPathCommand.prototype.GetY2()
|
||||||
|
ApiPathCommand.prototype.GetWR()
|
||||||
|
ApiPathCommand.prototype.GetHR()
|
||||||
|
ApiPathCommand.prototype.GetStartAngle()
|
||||||
|
ApiPathCommand.prototype.GetSweepAngle()
|
||||||
|
```
|
||||||
|
|
||||||
|
## 9.0.4
|
||||||
|
|
||||||
|
### New features
|
||||||
|
|
||||||
|
* Added support for woff2 fonts
|
||||||
|
* Added the Suggest a Feature item to the editors File menu
|
||||||
|
|
||||||
|
#### Document Editor
|
||||||
|
|
||||||
|
* Improved usability when working with allowed areas
|
||||||
|
|
||||||
|
#### Customization
|
||||||
|
|
||||||
|
* Added the `customization.suggestFeature` parameter
|
||||||
|
|
||||||
|
#### Plugins
|
||||||
|
|
||||||
|
* Added AI, Photo Editor, MathType, OCR, Typograf, Doc2md, LanguageTool,
|
||||||
|
DeepL, Thesaurus, Speech input and Zotero plugins to the server version
|
||||||
|
distribution with ONLYOFFICE branding
|
||||||
|
|
||||||
|
### Fixes
|
||||||
|
|
||||||
|
#### All Editors
|
||||||
|
|
||||||
|
* Fixed display of the scroll bar for the Modern Dark theme
|
||||||
|
* Fixed display of the table creation matrix in the Insert -> Table menu
|
||||||
|
for the Modern Light / Dark themes
|
||||||
|
* Fixed display of the error window when the connection is broken
|
||||||
|
after 2 minutes of waiting
|
||||||
|
* Fixed incorrect undo after composite input of text into an autoshape
|
||||||
|
in the Fast Co-editing mode
|
||||||
|
|
||||||
|
#### Document Editor
|
||||||
|
|
||||||
|
* Fixed the sequence of recording table settings to the file
|
||||||
|
* Forbidden execution of the Javascript code for a custom property in a document
|
||||||
|
* Fixed re-applying text formatting in an autoshape using hotkeys
|
||||||
|
* Fixed an error when reading a color with the "automatic" value
|
||||||
|
or writing it to a file
|
||||||
|
* Disabled the ability to delete text outside the allowed area for filling in
|
||||||
|
* Fixed deletion of characters when opening the `TXT` file for editing
|
||||||
|
* Fixed display of the password request window to remove file protection
|
||||||
|
in other editors
|
||||||
|
* Fixed recalculating the position of an autoshape with
|
||||||
|
the `Resize shape to fit text`
|
||||||
|
flag when changing text formatting
|
||||||
|
* Fixed crash when autocorrecting in a graphical formula (equation)
|
||||||
|
* Fixed display of the Abstract Numbering Definition Identifier numbering
|
||||||
|
in the `DOCX` file
|
||||||
|
* Removed an incorrect item in the Paste options menu for
|
||||||
|
the "Chart Editor" window
|
||||||
|
|
||||||
|
#### Spreadsheet Editor
|
||||||
|
|
||||||
|
* Fixed positioning of RTL text and graphics when saving the `XLSX` file
|
||||||
|
to an image
|
||||||
|
* Fixed hanging of the editor when copying rows / columns in some browsers
|
||||||
|
* Fixed formatting change for several cells with mixed text format
|
||||||
|
* Fixed the size of the pasted image of the copied area when scale
|
||||||
|
is higher than 100%
|
||||||
|
* Fixed display of scroll bars when uploading a new version of the `XLSX` file
|
||||||
|
after connection break
|
||||||
|
* Fixed crash when copying / pasting a cell with conditional formatting
|
||||||
|
in the `XLSX` file
|
||||||
|
* Fixed calculation of number of pages when saving the `ODS` file to `PNG`/`JPG`
|
||||||
|
* Fixed display of percent sign (%) in combination with a number
|
||||||
|
* Fixed an error when opening the saved `ODS` file in MS Excel
|
||||||
|
* Fixed the position when pasting a copied cell range as a Picture (Paste options)
|
||||||
|
for an RTL file
|
||||||
|
* Fixed display of text in the Formula bar in RTL languages
|
||||||
|
* Fixed crash when when opening a sheet with charts in the `XLSX` file
|
||||||
|
where multiple gradient points are used
|
||||||
|
* Fixed crash when when resizing a line chart with a lot of data in the `XLSX` file
|
||||||
|
|
||||||
|
#### Presentation Editor
|
||||||
|
|
||||||
|
* Fixed an error when clicking in the working area after deleting all slides
|
||||||
|
in the `ODP` file
|
||||||
|
* Fixed translation of the "Transitions" tab in Danish
|
||||||
|
|
||||||
|
#### Forms
|
||||||
|
|
||||||
|
* Fixed display of field names in Adobe Acrobat with the same name
|
||||||
|
specified in Cyrillic
|
||||||
|
* Fixed display of text for the field with the Password format
|
||||||
|
* Fixed input of text in the form field if the page is rotated
|
||||||
|
* Fixed locking of the Format list when the Multiline option is enabled
|
||||||
|
for the Text field
|
||||||
|
|
||||||
|
#### PDF Editor
|
||||||
|
|
||||||
|
* Fixed opening of the context menu after connection break
|
||||||
|
* Fixed adding comments to stamps
|
||||||
|
* Fixed applying the AutoFit option if the Scroll Long Text is not enabled
|
||||||
|
|
||||||
|
#### Convert
|
||||||
|
|
||||||
|
* Fixed crash when converting some `PPTX` files to `JPG` / `PNG` / `PDF`
|
||||||
|
* Fixed crash when converting the `XLSM` file to `XLSB` via x2t
|
||||||
|
* Fixed crash when converting the `PPTX` file to `PNG` via x2t
|
||||||
|
* Fixed crash when converting the `XLSM` file to `PNG` via x2t
|
||||||
|
* Fixed display of the “x” symbol after converting the `DOC` file to `DOCX`
|
||||||
|
* Fixed crash when converting the `DOCX` file to `JPG` / `PNG` / `PDF` via x2t
|
||||||
|
* Fixed crash when converting the `ODT` file to `DOCT` via x2t
|
||||||
|
* Fixed crash when converting the `ODS` file to `JPG` / `PNG` / `PDF` via x2t
|
||||||
|
* Fixed crash when converting the `ODS` file to `XLST` via x2t
|
||||||
|
* Fixed crash when converting a binary file containing an `SVG` image
|
||||||
|
to `XLSX` via x2t
|
||||||
|
* Fixed crash when converting the `KEY` file to `PPTT` via x2t
|
||||||
|
|
||||||
|
#### Back-end
|
||||||
|
|
||||||
|
* Fixed an issue with synchronization of the AI settings in k8s
|
||||||
|
between several document servers
|
||||||
|
* Fixed slow `PDF` opening in the WOPI test example if JWT is disabled
|
||||||
|
|
||||||
|
#### Mobile
|
||||||
|
|
||||||
|
* Fixed display of the `Switch to desktop` button on the toolbar for tablets
|
||||||
|
* Fixed the order of slides in the slideshow mode
|
||||||
|
* Fixed an error when clicking an image on a slide in the `PPTX` file
|
||||||
|
|
||||||
|
## 9.0.3
|
||||||
|
|
||||||
|
### New features
|
||||||
|
|
||||||
|
#### Spreadsheet Editor
|
||||||
|
|
||||||
|
* Enabled the ability to insert a range of cells as an image
|
||||||
|
using navigator.clipboard ([DocumentServer#985](https://github.com/ONLYOFFICE/DocumentServer/issues/985))
|
||||||
|
|
||||||
|
#### Customization
|
||||||
|
|
||||||
|
* Added the ability to hide the document title in the toolbar
|
||||||
|
using the `customization.toolbarHideFileName` parameter
|
||||||
|
|
||||||
|
### Fixes
|
||||||
|
|
||||||
|
#### All Editors
|
||||||
|
|
||||||
|
* The display of the cursor and text selection is now limited by the size
|
||||||
|
of the object/shape
|
||||||
|
* Fixed some icons for Modern themes when the interface scale
|
||||||
|
is higher than 200%
|
||||||
|
* Improved appearance of the autoshape Merge/Flip icons for the Modern themes
|
||||||
|
|
||||||
|
#### Document Editor
|
||||||
|
|
||||||
|
* Fixed stopping work of the editor when editing footer in some `DOCX` files
|
||||||
|
* Fixed errors during Compare/Combine/Text from file operations with files
|
||||||
|
containing images
|
||||||
|
* Fixed a crash when restoring a placeholder with a list when deleting
|
||||||
|
Content Control content
|
||||||
|
* Fixed significant increasing of the file size due to including CJK fonts
|
||||||
|
when exporting to `PDF` ([DocumentServer#2934](https://github.com/ONLYOFFICE/DocumentServer/issues/2934))
|
||||||
|
|
||||||
|
#### Spreadsheet Editor
|
||||||
|
|
||||||
|
* Fixed stopping work of the editor when trying to reference
|
||||||
|
a cell with a formula ([DocumentServer#3314](https://github.com/ONLYOFFICE/DocumentServer/issues/3314))
|
||||||
|
* Fixed appearing the #NAME error in the final file when using
|
||||||
|
a custom function and exporting to `PDF`
|
||||||
|
* Fixed a problem with saving custom function to a file
|
||||||
|
* Fixed an issue with autofitting row height when changing column width
|
||||||
|
if Wrap Text is applied to a cell
|
||||||
|
* Fixed display of the Zoom option value in the bottom toolbar in RTL UI
|
||||||
|
with the Sheet RTL option disabled
|
||||||
|
* Fixed the incorrect position of the percent sign in the status bar for Zoom
|
||||||
|
with Chinese (Simplified) ([DocumentServer#3313](https://github.com/ONLYOFFICE/DocumentServer/issues/3313))
|
||||||
|
|
||||||
|
#### Presentation Editor
|
||||||
|
|
||||||
|
* Fixed stopping work of the editor when applying some animations
|
||||||
|
from the Emphasis Effects section to an image
|
||||||
|
* Fixed the editor crash when deleting slides sequentially from preview panel
|
||||||
|
* Fixed stopping work of the editor when copying all content on the slide
|
||||||
|
in some `PPTX` files
|
||||||
|
* Fixed incorrect translations of tools in the Draw menu
|
||||||
|
of the Presenter View window
|
||||||
|
|
||||||
|
#### Forms
|
||||||
|
|
||||||
|
* Fixed stopping work of the editor after applying the TextArt setting
|
||||||
|
to the Signature field
|
||||||
|
* Fixed stopping work of the editor when restoring a file connection
|
||||||
|
after a long period of inactivity
|
||||||
|
* Fixed cursor change for Content Control buttons
|
||||||
|
* Fixed missing the Clear Fields icons in the form viewing mode
|
||||||
|
for the Modern themes
|
||||||
|
|
||||||
|
#### PDF Editor
|
||||||
|
|
||||||
|
* Fixed stopping work of the editor when performing Cut/Paste operations
|
||||||
|
simultaneously on the thumbnail panel
|
||||||
|
* Fixed display of the text after breaking and restoring a session when working
|
||||||
|
with some `PDF` files
|
||||||
|
* Fixed saving form field settings when there are no other changes
|
||||||
|
in the editor
|
||||||
|
* Blocked the ability to change the contents of the document
|
||||||
|
when the connection is lost
|
||||||
|
* Fixed an error when trying to copy page contents from the thumbnail panel
|
||||||
|
for `XPS/DjVu`
|
||||||
|
* Blocked the ability to display of the form field titles in the embedded mode
|
||||||
|
* Fixed display of the form field highlight when undoing and redoing actions
|
||||||
|
* Fixed blocking the ability to enter text immediately after inserting
|
||||||
|
a Text Comment
|
||||||
|
|
||||||
|
#### Diagram
|
||||||
|
|
||||||
|
* Fixed display of the slide in the working area when opening some `VSTX` files
|
||||||
|
|
||||||
|
#### Convert
|
||||||
|
|
||||||
|
* Fixed crash when converting some `DOCX` files to an image
|
||||||
|
* Fixed crash when converting some `HWP` files to the binary format
|
||||||
|
* Fixed endless conversion of some `HWP` files to the binary format
|
||||||
|
* Fixed endless conversion of some `DOC` files to the binary format
|
||||||
|
* Fixed the appearance of an error when opening the result of converting
|
||||||
|
some `HWP` files to `DOCX` in third-party editors
|
||||||
|
* Fixed crash when converting some `DOC` files to the binary format
|
||||||
|
* Fixed the appearance of an error when opening the result of converting
|
||||||
|
some `XLS` files to `XLSX` in third-party editors
|
||||||
|
* Fixed crash when converting some `DOCX` files to the binary format
|
||||||
|
* Fixed the difference in display of autoshapes after converting
|
||||||
|
some `VSDX` files to `PNG`
|
||||||
|
|
||||||
|
#### Back-end
|
||||||
|
|
||||||
|
* Fixed Configuration save error when saving or resetting AI settings
|
||||||
|
on /info when using own runtime.json
|
||||||
|
|
||||||
|
#### Mobile
|
||||||
|
|
||||||
|
* Fixed the ability to copy contents when initializing the editor
|
||||||
|
with the `permissions.copy: false` parameter
|
||||||
|
|
||||||
## 9.0.2
|
## 9.0.2
|
||||||
|
|
||||||
### Fixes
|
### Fixes
|
||||||
|
|||||||
239
Dockerfile
Normal file
239
Dockerfile
Normal file
@@ -0,0 +1,239 @@
|
|||||||
|
ARG BASE_VERSION=24.04
|
||||||
|
ARG BASE_IMAGE=ubuntu:$BASE_VERSION
|
||||||
|
|
||||||
|
FROM ${BASE_IMAGE} AS documentserver
|
||||||
|
LABEL maintainer="ONLYOFFICE <support@onlyoffice.com>"
|
||||||
|
LABEL version="9.2.0"
|
||||||
|
LABEL description="ONLYOFFICE DocumentServer for ARM64 and AMD64"
|
||||||
|
|
||||||
|
ARG BASE_VERSION
|
||||||
|
ARG PG_VERSION=16
|
||||||
|
ARG PACKAGE_SUFFIX=t64
|
||||||
|
|
||||||
|
# Oracle Instant Client versions
|
||||||
|
ENV OC_RELEASE_NUM=23
|
||||||
|
ENV OC_RU_VER=7
|
||||||
|
ENV OC_RU_REVISION_VER=0
|
||||||
|
ENV OC_RESERVED_NUM=25
|
||||||
|
ENV OC_RU_DATE=01
|
||||||
|
ENV OC_PATH=${OC_RELEASE_NUM}${OC_RU_VER}0000
|
||||||
|
ENV OC_FILE_SUFFIX=${OC_RELEASE_NUM}.${OC_RU_VER}.${OC_RU_REVISION_VER}.${OC_RESERVED_NUM}.${OC_RU_DATE}
|
||||||
|
ENV OC_VER_DIR=${OC_RELEASE_NUM}_${OC_RU_VER}
|
||||||
|
ENV OC_DOWNLOAD_URL=https://download.oracle.com/otn_software/linux/instantclient/${OC_PATH}
|
||||||
|
|
||||||
|
# Locale and environment
|
||||||
|
ENV LANG=en_US.UTF-8 \
|
||||||
|
LANGUAGE=en_US:en \
|
||||||
|
LC_ALL=en_US.UTF-8 \
|
||||||
|
DEBIAN_FRONTEND=noninteractive \
|
||||||
|
PG_VERSION=${PG_VERSION} \
|
||||||
|
BASE_VERSION=${BASE_VERSION}
|
||||||
|
|
||||||
|
# Company and product info
|
||||||
|
ARG COMPANY_NAME=onlyoffice
|
||||||
|
ARG PRODUCT_NAME=documentserver
|
||||||
|
ARG PRODUCT_EDITION=
|
||||||
|
ARG PACKAGE_VERSION=9.2.0
|
||||||
|
ARG TARGETARCH
|
||||||
|
ARG PACKAGE_BASEURL="http://download.onlyoffice.com/install/documentserver/linux"
|
||||||
|
|
||||||
|
ENV COMPANY_NAME=$COMPANY_NAME \
|
||||||
|
PRODUCT_NAME=$PRODUCT_NAME \
|
||||||
|
PRODUCT_EDITION=$PRODUCT_EDITION \
|
||||||
|
DS_PLUGIN_INSTALLATION=false \
|
||||||
|
DS_DOCKER_INSTALLATION=true
|
||||||
|
|
||||||
|
# ============================================
|
||||||
|
# HARDCODED CONFIGURATION - NO ENV VARS NEEDED
|
||||||
|
# ============================================
|
||||||
|
# Database Configuration
|
||||||
|
ENV DB_TYPE=postgres \
|
||||||
|
DB_HOST=localhost \
|
||||||
|
DB_PORT=5432 \
|
||||||
|
DB_NAME=onlyoffice \
|
||||||
|
DB_USER=onlyoffice \
|
||||||
|
DB_PWD=onlyoffice
|
||||||
|
|
||||||
|
# Redis Configuration
|
||||||
|
ENV REDIS_SERVER_HOST=localhost \
|
||||||
|
REDIS_SERVER_PORT=6379 \
|
||||||
|
REDIS_ENABLED=true
|
||||||
|
|
||||||
|
# RabbitMQ Configuration
|
||||||
|
ENV AMQP_SERVER_HOST=localhost \
|
||||||
|
AMQP_SERVER_PORT=5672 \
|
||||||
|
AMQP_SERVER_USER=guest \
|
||||||
|
AMQP_SERVER_PWD=guest \
|
||||||
|
AMQP_SERVER_PROTO=amqp
|
||||||
|
|
||||||
|
# JWT Configuration (disabled by default)
|
||||||
|
ENV JWT_ENABLED=false \
|
||||||
|
JWT_SECRET=secret \
|
||||||
|
JWT_HEADER=Authorization \
|
||||||
|
JWT_IN_BODY=false
|
||||||
|
|
||||||
|
# Other settings
|
||||||
|
ENV WOPI_ENABLED=false \
|
||||||
|
GENERATE_FONTS=true \
|
||||||
|
METRICS_ENABLED=false \
|
||||||
|
PLUGINS_ENABLED=true \
|
||||||
|
DS_LOG_LEVEL=WARN
|
||||||
|
|
||||||
|
# Create policy to allow services to start
|
||||||
|
RUN echo "#!/bin/sh\nexit 0" > /usr/sbin/policy-rc.d
|
||||||
|
|
||||||
|
# Install base packages
|
||||||
|
RUN apt-get -y update && \
|
||||||
|
apt-get -yq install \
|
||||||
|
wget \
|
||||||
|
apt-transport-https \
|
||||||
|
gnupg \
|
||||||
|
locales \
|
||||||
|
lsb-release && \
|
||||||
|
locale-gen en_US.UTF-8
|
||||||
|
|
||||||
|
# Add Microsoft repository for SQL tools
|
||||||
|
RUN wget -q -O /etc/apt/sources.list.d/mssql-release.list \
|
||||||
|
"https://packages.microsoft.com/config/ubuntu/$BASE_VERSION/prod.list" && \
|
||||||
|
wget -q -O /tmp/microsoft.asc https://packages.microsoft.com/keys/microsoft.asc && \
|
||||||
|
apt-key add /tmp/microsoft.asc && \
|
||||||
|
gpg --dearmor -o /usr/share/keyrings/microsoft-prod.gpg < /tmp/microsoft.asc
|
||||||
|
|
||||||
|
# Accept Microsoft fonts EULA
|
||||||
|
RUN echo ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true | debconf-set-selections
|
||||||
|
|
||||||
|
# Install all required packages
|
||||||
|
RUN apt-get -y update && \
|
||||||
|
ACCEPT_EULA=Y apt-get -yq install \
|
||||||
|
adduser \
|
||||||
|
apt-utils \
|
||||||
|
bomstrip \
|
||||||
|
certbot \
|
||||||
|
cron \
|
||||||
|
curl \
|
||||||
|
htop \
|
||||||
|
libaio1${PACKAGE_SUFFIX} \
|
||||||
|
libasound2${PACKAGE_SUFFIX} \
|
||||||
|
libboost-regex-dev \
|
||||||
|
libcairo2 \
|
||||||
|
libcurl3-gnutls \
|
||||||
|
libcurl4 \
|
||||||
|
libgtk-3-0 \
|
||||||
|
libnspr4 \
|
||||||
|
libnss3 \
|
||||||
|
libstdc++6 \
|
||||||
|
libxml2 \
|
||||||
|
libxss1 \
|
||||||
|
libxtst6 \
|
||||||
|
mssql-tools18 \
|
||||||
|
mysql-client \
|
||||||
|
nano \
|
||||||
|
net-tools \
|
||||||
|
netcat-openbsd \
|
||||||
|
nginx-extras \
|
||||||
|
postgresql \
|
||||||
|
postgresql-client \
|
||||||
|
pwgen \
|
||||||
|
rabbitmq-server \
|
||||||
|
redis-server \
|
||||||
|
sudo \
|
||||||
|
supervisor \
|
||||||
|
ttf-mscorefonts-installer \
|
||||||
|
unixodbc-dev \
|
||||||
|
unzip \
|
||||||
|
xvfb \
|
||||||
|
xxd \
|
||||||
|
zlib1g || dpkg --configure -a
|
||||||
|
|
||||||
|
# Verify Microsoft fonts installation
|
||||||
|
RUN if [ $(find /usr/share/fonts/truetype/msttcorefonts -maxdepth 1 -type f -iname '*.ttf' | wc -l) -lt 30 ]; then \
|
||||||
|
echo 'msttcorefonts failed to download'; exit 1; \
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Configure RabbitMQ for single CPU
|
||||||
|
RUN echo "SERVER_ADDITIONAL_ERL_ARGS=\"+S 1:1\"" | tee -a /etc/rabbitmq/rabbitmq-env.conf
|
||||||
|
|
||||||
|
# Configure Redis to bind to localhost only
|
||||||
|
RUN sed -i "s/bind .*/bind 127.0.0.1/g" /etc/redis/redis.conf
|
||||||
|
|
||||||
|
# Add wasm mime type to nginx
|
||||||
|
RUN sed 's|\(application\/zip.*\)|\1\n application\/wasm wasm;|' -i /etc/nginx/mime.types
|
||||||
|
|
||||||
|
# Configure PostgreSQL
|
||||||
|
RUN pg_conftool $PG_VERSION main set listen_addresses 'localhost'
|
||||||
|
|
||||||
|
# Start PostgreSQL and create user/database
|
||||||
|
RUN service postgresql restart && \
|
||||||
|
sudo -u postgres psql -c "CREATE USER ${DB_USER} WITH password '${DB_PWD}';" && \
|
||||||
|
sudo -u postgres psql -c "CREATE DATABASE ${DB_NAME} OWNER ${DB_USER};"
|
||||||
|
|
||||||
|
# Download and install Oracle Instant Client (architecture-specific)
|
||||||
|
RUN wget -O basic.zip ${OC_DOWNLOAD_URL}/instantclient-basic-linux.$(dpkg --print-architecture | sed 's/amd64/x64/')-${OC_FILE_SUFFIX}.zip && \
|
||||||
|
wget -O sqlplus.zip ${OC_DOWNLOAD_URL}/instantclient-sqlplus-linux.$(dpkg --print-architecture | sed 's/amd64/x64/')-${OC_FILE_SUFFIX}.zip && \
|
||||||
|
unzip -o basic.zip -d /usr/share && \
|
||||||
|
unzip -o sqlplus.zip -d /usr/share && \
|
||||||
|
mv /usr/share/instantclient_${OC_VER_DIR} /usr/share/instantclient && \
|
||||||
|
find /usr/lib /lib -name "libaio.so.1$PACKAGE_SUFFIX" -exec bash -c 'ln -sf "$0" "$(dirname "$0")/libaio.so.1"' {} \; && \
|
||||||
|
rm -f basic.zip sqlplus.zip
|
||||||
|
|
||||||
|
# Stop services that were started during build
|
||||||
|
RUN service postgresql stop && \
|
||||||
|
service redis-server stop && \
|
||||||
|
service rabbitmq-server stop && \
|
||||||
|
service supervisor stop && \
|
||||||
|
service nginx stop
|
||||||
|
|
||||||
|
# Clean up apt cache
|
||||||
|
RUN rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Copy configuration files
|
||||||
|
COPY config/supervisor/supervisor /etc/init.d/
|
||||||
|
COPY config/supervisor/ds/*.conf /etc/supervisor/conf.d/
|
||||||
|
COPY run-document-server.sh /app/ds/run-document-server.sh
|
||||||
|
|
||||||
|
# Create sqlplus wrapper
|
||||||
|
RUN mkdir -p /usr/bin && \
|
||||||
|
echo '#!/bin/bash' > /usr/bin/sqlplus && \
|
||||||
|
echo 'export LD_LIBRARY_PATH=/usr/share/instantclient:$LD_LIBRARY_PATH' >> /usr/bin/sqlplus && \
|
||||||
|
echo 'exec /usr/share/instantclient/sqlplus "$@"' >> /usr/bin/sqlplus && \
|
||||||
|
chmod +x /usr/bin/sqlplus
|
||||||
|
|
||||||
|
# Expose ports
|
||||||
|
EXPOSE 80 443
|
||||||
|
|
||||||
|
# Download and install ONLYOFFICE DocumentServer package
|
||||||
|
RUN PACKAGE_FILE="${COMPANY_NAME}-${PRODUCT_NAME}${PRODUCT_EDITION}${PACKAGE_VERSION:+_$PACKAGE_VERSION}_${TARGETARCH:-$(dpkg --print-architecture)}.deb" && \
|
||||||
|
echo "Downloading package: $PACKAGE_BASEURL/$PACKAGE_FILE" && \
|
||||||
|
wget -q -P /tmp "$PACKAGE_BASEURL/$PACKAGE_FILE" && \
|
||||||
|
apt-get -y update && \
|
||||||
|
service postgresql start && \
|
||||||
|
apt-get -yq install /tmp/$PACKAGE_FILE && \
|
||||||
|
# Clean up temp database used during installation
|
||||||
|
PGPASSWORD=$DB_PWD dropdb -h localhost -p 5432 -U $DB_USER $DB_NAME 2>/dev/null || true && \
|
||||||
|
sudo -u postgres psql -c "DROP ROLE IF EXISTS ${DB_USER};" 2>/dev/null || true && \
|
||||||
|
service postgresql stop && \
|
||||||
|
chmod 755 /etc/init.d/supervisor && \
|
||||||
|
sed "s/COMPANY_NAME/${COMPANY_NAME}/g" -i /etc/supervisor/conf.d/*.conf && \
|
||||||
|
service supervisor stop && \
|
||||||
|
chmod 755 /app/ds/*.sh && \
|
||||||
|
# Add GO command for MSSQL scripts
|
||||||
|
printf "\nGO" >> "/var/www/$COMPANY_NAME/documentserver/server/schema/mssql/createdb.sql" && \
|
||||||
|
printf "\nGO" >> "/var/www/$COMPANY_NAME/documentserver/server/schema/mssql/removetbl.sql" && \
|
||||||
|
# Add exit command for Oracle scripts
|
||||||
|
printf "\nexit" >> "/var/www/$COMPANY_NAME/documentserver/server/schema/oracle/createdb.sql" && \
|
||||||
|
printf "\nexit" >> "/var/www/$COMPANY_NAME/documentserver/server/schema/oracle/removetbl.sql" && \
|
||||||
|
rm -f /tmp/$PACKAGE_FILE && \
|
||||||
|
rm -rf /var/log/$COMPANY_NAME && \
|
||||||
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Define volumes for persistent data
|
||||||
|
VOLUME /var/log/$COMPANY_NAME \
|
||||||
|
/var/lib/$COMPANY_NAME \
|
||||||
|
/var/www/$COMPANY_NAME/Data \
|
||||||
|
/var/lib/postgresql \
|
||||||
|
/var/lib/rabbitmq \
|
||||||
|
/var/lib/redis \
|
||||||
|
/usr/share/fonts/truetype/custom
|
||||||
|
|
||||||
|
# Set entrypoint
|
||||||
|
ENTRYPOINT ["/app/ds/run-document-server.sh"]
|
||||||
13
ROADMAP.md
13
ROADMAP.md
@@ -5,6 +5,19 @@ This document provides the roadmap of the planned ONLYOFFICE Document Server cha
|
|||||||
This is an updated and corrected version of the roadmap.
|
This is an updated and corrected version of the roadmap.
|
||||||
We also reserve the right to change it when necessary.
|
We also reserve the right to change it when necessary.
|
||||||
|
|
||||||
|
## Version 9.2
|
||||||
|
|
||||||
|
### All editors
|
||||||
|
|
||||||
|
* Customizing keyboard shortcuts
|
||||||
|
* Recording macros for all editors
|
||||||
|
* Additional settings in the Admin Panel
|
||||||
|
* New API methods for working with all editors
|
||||||
|
|
||||||
|
### PDF Editor
|
||||||
|
|
||||||
|
* Ability to set the color for the Redact option
|
||||||
|
|
||||||
## Version 9.1
|
## Version 9.1
|
||||||
|
|
||||||
### All editors
|
### All editors
|
||||||
|
|||||||
18
config/supervisor/ds/ds-converter.conf
Normal file
18
config/supervisor/ds/ds-converter.conf
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
[program:ds-converter]
|
||||||
|
command=/var/www/COMPANY_NAME/documentserver/server/FileConverter/converter
|
||||||
|
directory=/var/www/COMPANY_NAME/documentserver/server/FileConverter
|
||||||
|
user=ds
|
||||||
|
autostart=true
|
||||||
|
autorestart=true
|
||||||
|
startsecs=10
|
||||||
|
startretries=3
|
||||||
|
stopwaitsecs=60
|
||||||
|
killasgroup=true
|
||||||
|
stopasgroup=true
|
||||||
|
stdout_logfile=/var/log/COMPANY_NAME/documentserver/converter/out.log
|
||||||
|
stderr_logfile=/var/log/COMPANY_NAME/documentserver/converter/err.log
|
||||||
|
stdout_logfile_maxbytes=10MB
|
||||||
|
stderr_logfile_maxbytes=10MB
|
||||||
|
stdout_logfile_backups=5
|
||||||
|
stderr_logfile_backups=5
|
||||||
|
environment=NODE_ENV="production-linux",NODE_CONFIG_DIR="/etc/COMPANY_NAME/documentserver",NODE_DISABLE_COLORS="1"
|
||||||
18
config/supervisor/ds/ds-docservice.conf
Normal file
18
config/supervisor/ds/ds-docservice.conf
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
[program:ds-docservice]
|
||||||
|
command=/var/www/COMPANY_NAME/documentserver/server/DocService/docservice
|
||||||
|
directory=/var/www/COMPANY_NAME/documentserver/server/DocService
|
||||||
|
user=ds
|
||||||
|
autostart=true
|
||||||
|
autorestart=true
|
||||||
|
startsecs=10
|
||||||
|
startretries=3
|
||||||
|
stopwaitsecs=60
|
||||||
|
killasgroup=true
|
||||||
|
stopasgroup=true
|
||||||
|
stdout_logfile=/var/log/COMPANY_NAME/documentserver/docservice/out.log
|
||||||
|
stderr_logfile=/var/log/COMPANY_NAME/documentserver/docservice/err.log
|
||||||
|
stdout_logfile_maxbytes=10MB
|
||||||
|
stderr_logfile_maxbytes=10MB
|
||||||
|
stdout_logfile_backups=5
|
||||||
|
stderr_logfile_backups=5
|
||||||
|
environment=NODE_ENV="production-linux",NODE_CONFIG_DIR="/etc/COMPANY_NAME/documentserver",NODE_DISABLE_COLORS="1"
|
||||||
18
config/supervisor/ds/ds-metrics.conf
Normal file
18
config/supervisor/ds/ds-metrics.conf
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
[program:ds-metrics]
|
||||||
|
command=/var/www/COMPANY_NAME/documentserver/server/Metrics/metrics
|
||||||
|
directory=/var/www/COMPANY_NAME/documentserver/server/Metrics
|
||||||
|
user=ds
|
||||||
|
autostart=false
|
||||||
|
autorestart=true
|
||||||
|
startsecs=10
|
||||||
|
startretries=3
|
||||||
|
stopwaitsecs=10
|
||||||
|
killasgroup=true
|
||||||
|
stopasgroup=true
|
||||||
|
stdout_logfile=/var/log/COMPANY_NAME/documentserver/metrics/out.log
|
||||||
|
stderr_logfile=/var/log/COMPANY_NAME/documentserver/metrics/err.log
|
||||||
|
stdout_logfile_maxbytes=10MB
|
||||||
|
stderr_logfile_maxbytes=10MB
|
||||||
|
stdout_logfile_backups=5
|
||||||
|
stderr_logfile_backups=5
|
||||||
|
environment=NODE_ENV="production-linux",NODE_CONFIG_DIR="/etc/COMPANY_NAME/documentserver",NODE_DISABLE_COLORS="1"
|
||||||
45
config/supervisor/supervisor
Normal file
45
config/supervisor/supervisor
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
### BEGIN INIT INFO
|
||||||
|
# Provides: supervisor
|
||||||
|
# Required-Start: $remote_fs $syslog
|
||||||
|
# Required-Stop: $remote_fs $syslog
|
||||||
|
# Default-Start: 2 3 4 5
|
||||||
|
# Default-Stop: 0 1 6
|
||||||
|
# Short-Description: Supervisor init script
|
||||||
|
# Description: Supervisor is a client/server system for controlling
|
||||||
|
# process state under UNIX-like operating systems.
|
||||||
|
### END INIT INFO
|
||||||
|
|
||||||
|
SUPERVISORD=/usr/bin/supervisord
|
||||||
|
SUPERVISORCTL=/usr/bin/supervisorctl
|
||||||
|
PIDFILE=/var/run/supervisord.pid
|
||||||
|
CONF=/etc/supervisor/supervisord.conf
|
||||||
|
|
||||||
|
. /lib/lsb/init-functions
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
start)
|
||||||
|
log_daemon_msg "Starting supervisor" "supervisord"
|
||||||
|
start-stop-daemon --start --quiet --pidfile $PIDFILE --exec $SUPERVISORD -- -c $CONF
|
||||||
|
log_end_msg $?
|
||||||
|
;;
|
||||||
|
stop)
|
||||||
|
log_daemon_msg "Stopping supervisor" "supervisord"
|
||||||
|
start-stop-daemon --stop --quiet --pidfile $PIDFILE
|
||||||
|
log_end_msg $?
|
||||||
|
;;
|
||||||
|
restart)
|
||||||
|
$0 stop
|
||||||
|
sleep 1
|
||||||
|
$0 start
|
||||||
|
;;
|
||||||
|
status)
|
||||||
|
status_of_proc -p $PIDFILE $SUPERVISORD supervisor && exit 0 || exit $?
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Usage: $0 {start|stop|restart|status}"
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit 0
|
||||||
2
core
2
core
Submodule core updated: bcc5f67ec8...b1b3e1fb7c
136
docker-compose.yml
Normal file
136
docker-compose.yml
Normal file
@@ -0,0 +1,136 @@
|
|||||||
|
# ONLYOFFICE DocumentServer Docker Compose Configuration
|
||||||
|
# All services run with hardcoded credentials - no environment variables needed
|
||||||
|
# Works on both ARM64 and AMD64 architectures
|
||||||
|
|
||||||
|
services:
|
||||||
|
# ===========================================
|
||||||
|
# ONLYOFFICE DocumentServer - Main Service
|
||||||
|
# ===========================================
|
||||||
|
onlyoffice-documentserver:
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
args:
|
||||||
|
- PACKAGE_VERSION=9.2.0
|
||||||
|
image: onlyoffice/documentserver:9.2.0
|
||||||
|
container_name: onlyoffice-documentserver
|
||||||
|
depends_on:
|
||||||
|
onlyoffice-postgresql:
|
||||||
|
condition: service_healthy
|
||||||
|
onlyoffice-rabbitmq:
|
||||||
|
condition: service_healthy
|
||||||
|
environment:
|
||||||
|
# Database Configuration
|
||||||
|
- DB_TYPE=postgres
|
||||||
|
- DB_HOST=onlyoffice-postgresql
|
||||||
|
- DB_PORT=5432
|
||||||
|
- DB_NAME=onlyoffice
|
||||||
|
- DB_USER=onlyoffice
|
||||||
|
- DB_PWD=onlyoffice
|
||||||
|
# RabbitMQ Configuration
|
||||||
|
- AMQP_URI=amqp://guest:guest@onlyoffice-rabbitmq:5672
|
||||||
|
- AMQP_SERVER_HOST=onlyoffice-rabbitmq
|
||||||
|
- AMQP_SERVER_PORT=5672
|
||||||
|
- AMQP_SERVER_USER=guest
|
||||||
|
- AMQP_SERVER_PWD=guest
|
||||||
|
# Redis Configuration (using built-in Redis)
|
||||||
|
- REDIS_SERVER_HOST=localhost
|
||||||
|
- REDIS_SERVER_PORT=6379
|
||||||
|
- REDIS_ENABLED=true
|
||||||
|
# JWT Configuration (disabled for simplicity)
|
||||||
|
- JWT_ENABLED=false
|
||||||
|
- JWT_SECRET=secret
|
||||||
|
- JWT_HEADER=Authorization
|
||||||
|
- JWT_IN_BODY=false
|
||||||
|
# Other settings
|
||||||
|
- WOPI_ENABLED=false
|
||||||
|
- GENERATE_FONTS=true
|
||||||
|
- PLUGINS_ENABLED=true
|
||||||
|
- DS_LOG_LEVEL=WARN
|
||||||
|
ports:
|
||||||
|
- '80:80'
|
||||||
|
- '443:443'
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD", "curl", "-f", "http://localhost/healthcheck"]
|
||||||
|
interval: 30s
|
||||||
|
retries: 5
|
||||||
|
start_period: 120s
|
||||||
|
timeout: 10s
|
||||||
|
stdin_open: true
|
||||||
|
restart: always
|
||||||
|
stop_grace_period: 60s
|
||||||
|
volumes:
|
||||||
|
- ds_data:/var/www/onlyoffice/Data
|
||||||
|
- ds_logs:/var/log/onlyoffice
|
||||||
|
- ds_cache:/var/lib/onlyoffice/documentserver/App_Data/cache/files
|
||||||
|
- ds_fonts:/usr/share/fonts/truetype/custom
|
||||||
|
|
||||||
|
# ===========================================
|
||||||
|
# PostgreSQL Database
|
||||||
|
# ===========================================
|
||||||
|
onlyoffice-postgresql:
|
||||||
|
container_name: onlyoffice-postgresql
|
||||||
|
image: postgres:16
|
||||||
|
environment:
|
||||||
|
- POSTGRES_DB=onlyoffice
|
||||||
|
- POSTGRES_USER=onlyoffice
|
||||||
|
- POSTGRES_PASSWORD=onlyoffice
|
||||||
|
- POSTGRES_HOST_AUTH_METHOD=md5
|
||||||
|
restart: always
|
||||||
|
expose:
|
||||||
|
- '5432'
|
||||||
|
volumes:
|
||||||
|
- postgresql_data:/var/lib/postgresql/data
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD-SHELL", "pg_isready -U onlyoffice -d onlyoffice"]
|
||||||
|
interval: 10s
|
||||||
|
retries: 5
|
||||||
|
start_period: 10s
|
||||||
|
timeout: 5s
|
||||||
|
|
||||||
|
# ===========================================
|
||||||
|
# RabbitMQ Message Broker
|
||||||
|
# ===========================================
|
||||||
|
onlyoffice-rabbitmq:
|
||||||
|
container_name: onlyoffice-rabbitmq
|
||||||
|
image: rabbitmq:3-management
|
||||||
|
hostname: onlyoffice-rabbitmq
|
||||||
|
environment:
|
||||||
|
- RABBITMQ_DEFAULT_USER=guest
|
||||||
|
- RABBITMQ_DEFAULT_PASS=guest
|
||||||
|
restart: always
|
||||||
|
expose:
|
||||||
|
- '5672'
|
||||||
|
- '15672'
|
||||||
|
volumes:
|
||||||
|
- rabbitmq_data:/var/lib/rabbitmq
|
||||||
|
healthcheck:
|
||||||
|
test: ["CMD", "rabbitmq-diagnostics", "status"]
|
||||||
|
interval: 10s
|
||||||
|
retries: 5
|
||||||
|
start_period: 30s
|
||||||
|
timeout: 10s
|
||||||
|
|
||||||
|
# ===========================================
|
||||||
|
# Persistent Volumes
|
||||||
|
# ===========================================
|
||||||
|
volumes:
|
||||||
|
postgresql_data:
|
||||||
|
driver: local
|
||||||
|
rabbitmq_data:
|
||||||
|
driver: local
|
||||||
|
ds_data:
|
||||||
|
driver: local
|
||||||
|
ds_logs:
|
||||||
|
driver: local
|
||||||
|
ds_cache:
|
||||||
|
driver: local
|
||||||
|
ds_fonts:
|
||||||
|
driver: local
|
||||||
|
|
||||||
|
# ===========================================
|
||||||
|
# Network Configuration
|
||||||
|
# ===========================================
|
||||||
|
networks:
|
||||||
|
default:
|
||||||
|
name: onlyoffice-network
|
||||||
|
driver: bridge
|
||||||
359
run-document-server.sh
Normal file
359
run-document-server.sh
Normal file
@@ -0,0 +1,359 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# ONLYOFFICE DocumentServer Startup Script
|
||||||
|
# This script initializes and starts all required services
|
||||||
|
|
||||||
|
umask 0022
|
||||||
|
|
||||||
|
# ============================================
|
||||||
|
# HARDCODED CONFIGURATION
|
||||||
|
# ============================================
|
||||||
|
COMPANY_NAME=${COMPANY_NAME:-onlyoffice}
|
||||||
|
PRODUCT_NAME=${PRODUCT_NAME:-documentserver}
|
||||||
|
|
||||||
|
# Database Configuration
|
||||||
|
DB_TYPE=${DB_TYPE:-postgres}
|
||||||
|
DB_HOST=${DB_HOST:-localhost}
|
||||||
|
DB_PORT=${DB_PORT:-5432}
|
||||||
|
DB_NAME=${DB_NAME:-onlyoffice}
|
||||||
|
DB_USER=${DB_USER:-onlyoffice}
|
||||||
|
DB_PWD=${DB_PWD:-onlyoffice}
|
||||||
|
|
||||||
|
# Redis Configuration
|
||||||
|
REDIS_SERVER_HOST=${REDIS_SERVER_HOST:-localhost}
|
||||||
|
REDIS_SERVER_PORT=${REDIS_SERVER_PORT:-6379}
|
||||||
|
REDIS_ENABLED=${REDIS_ENABLED:-true}
|
||||||
|
|
||||||
|
# RabbitMQ Configuration
|
||||||
|
AMQP_SERVER_HOST=${AMQP_SERVER_HOST:-localhost}
|
||||||
|
AMQP_SERVER_PORT=${AMQP_SERVER_PORT:-5672}
|
||||||
|
AMQP_SERVER_USER=${AMQP_SERVER_USER:-guest}
|
||||||
|
AMQP_SERVER_PWD=${AMQP_SERVER_PWD:-guest}
|
||||||
|
AMQP_SERVER_PROTO=${AMQP_SERVER_PROTO:-amqp}
|
||||||
|
|
||||||
|
# JWT Configuration
|
||||||
|
JWT_ENABLED=${JWT_ENABLED:-false}
|
||||||
|
JWT_SECRET=${JWT_SECRET:-secret}
|
||||||
|
JWT_HEADER=${JWT_HEADER:-Authorization}
|
||||||
|
JWT_IN_BODY=${JWT_IN_BODY:-false}
|
||||||
|
|
||||||
|
# Other settings
|
||||||
|
WOPI_ENABLED=${WOPI_ENABLED:-false}
|
||||||
|
GENERATE_FONTS=${GENERATE_FONTS:-true}
|
||||||
|
PLUGINS_ENABLED=${PLUGINS_ENABLED:-true}
|
||||||
|
DS_LOG_LEVEL=${DS_LOG_LEVEL:-WARN}
|
||||||
|
NGINX_WORKER_PROCESSES=${NGINX_WORKER_PROCESSES:-1}
|
||||||
|
|
||||||
|
# ============================================
|
||||||
|
# DIRECTORIES
|
||||||
|
# ============================================
|
||||||
|
APP_DIR="/var/www/${COMPANY_NAME}/documentserver"
|
||||||
|
DATA_DIR="/var/www/${COMPANY_NAME}/Data"
|
||||||
|
PRIVATE_DATA_DIR="${DATA_DIR}/.private"
|
||||||
|
LOG_DIR="/var/log/${COMPANY_NAME}"
|
||||||
|
DS_LOG_DIR="${LOG_DIR}/documentserver"
|
||||||
|
LIB_DIR="/var/lib/${COMPANY_NAME}"
|
||||||
|
DS_LIB_DIR="${LIB_DIR}/documentserver"
|
||||||
|
CONF_DIR="/etc/${COMPANY_NAME}/documentserver"
|
||||||
|
PG_ROOT="/var/lib/postgresql"
|
||||||
|
PGDATA="${PG_ROOT}/${PG_VERSION:-16}/main"
|
||||||
|
REDIS_DATA="/var/lib/redis"
|
||||||
|
RABBITMQ_DATA="/var/lib/rabbitmq"
|
||||||
|
|
||||||
|
# ============================================
|
||||||
|
# FUNCTIONS
|
||||||
|
# ============================================
|
||||||
|
|
||||||
|
start_process() {
|
||||||
|
"$@" &
|
||||||
|
CHILD=$!
|
||||||
|
wait "$CHILD"
|
||||||
|
CHILD=""
|
||||||
|
}
|
||||||
|
|
||||||
|
clean_exit() {
|
||||||
|
[[ -z "$CHILD" ]] || kill -s SIGTERM "$CHILD" 2>/dev/null
|
||||||
|
/usr/bin/documentserver-prepare4shutdown.sh 2>/dev/null || true
|
||||||
|
exit
|
||||||
|
}
|
||||||
|
|
||||||
|
trap clean_exit SIGTERM SIGQUIT SIGABRT SIGINT
|
||||||
|
|
||||||
|
waiting_for_db() {
|
||||||
|
echo "Waiting for database connection..."
|
||||||
|
local RETRY=0
|
||||||
|
local MAX_RETRY=30
|
||||||
|
while ! PGPASSWORD="${DB_PWD}" psql -h "${DB_HOST}" -p "${DB_PORT}" -U "${DB_USER}" -d "${DB_NAME}" -c "SELECT 1" >/dev/null 2>&1; do
|
||||||
|
RETRY=$((RETRY + 1))
|
||||||
|
if [ $RETRY -ge $MAX_RETRY ]; then
|
||||||
|
echo "ERROR: Database connection failed after ${MAX_RETRY} attempts"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo " Attempt ${RETRY}/${MAX_RETRY}..."
|
||||||
|
sleep 2
|
||||||
|
done
|
||||||
|
echo "Database connection established!"
|
||||||
|
}
|
||||||
|
|
||||||
|
waiting_for_amqp() {
|
||||||
|
echo "Waiting for RabbitMQ connection..."
|
||||||
|
local RETRY=0
|
||||||
|
local MAX_RETRY=30
|
||||||
|
while ! nc -z "${AMQP_SERVER_HOST}" "${AMQP_SERVER_PORT}" 2>/dev/null; do
|
||||||
|
RETRY=$((RETRY + 1))
|
||||||
|
if [ $RETRY -ge $MAX_RETRY ]; then
|
||||||
|
echo "ERROR: RabbitMQ connection failed after ${MAX_RETRY} attempts"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo " Attempt ${RETRY}/${MAX_RETRY}..."
|
||||||
|
sleep 2
|
||||||
|
done
|
||||||
|
echo "RabbitMQ connection established!"
|
||||||
|
}
|
||||||
|
|
||||||
|
waiting_for_redis() {
|
||||||
|
echo "Waiting for Redis connection..."
|
||||||
|
local RETRY=0
|
||||||
|
local MAX_RETRY=30
|
||||||
|
while ! nc -z "${REDIS_SERVER_HOST}" "${REDIS_SERVER_PORT}" 2>/dev/null; do
|
||||||
|
RETRY=$((RETRY + 1))
|
||||||
|
if [ $RETRY -ge $MAX_RETRY ]; then
|
||||||
|
echo "ERROR: Redis connection failed after ${MAX_RETRY} attempts"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo " Attempt ${RETRY}/${MAX_RETRY}..."
|
||||||
|
sleep 2
|
||||||
|
done
|
||||||
|
echo "Redis connection established!"
|
||||||
|
}
|
||||||
|
|
||||||
|
create_postgresql_cluster() {
|
||||||
|
echo "Creating PostgreSQL cluster..."
|
||||||
|
sudo -u postgres /usr/lib/postgresql/${PG_VERSION:-16}/bin/initdb -D "${PGDATA}"
|
||||||
|
}
|
||||||
|
|
||||||
|
create_postgresql_db() {
|
||||||
|
echo "Creating PostgreSQL database..."
|
||||||
|
sudo -u postgres psql -c "CREATE USER ${DB_USER} WITH password '${DB_PWD}';" 2>/dev/null || true
|
||||||
|
sudo -u postgres psql -c "CREATE DATABASE ${DB_NAME} OWNER ${DB_USER};" 2>/dev/null || true
|
||||||
|
}
|
||||||
|
|
||||||
|
create_postgresql_tbl() {
|
||||||
|
echo "Creating database tables..."
|
||||||
|
PGPASSWORD="${DB_PWD}" psql -h "${DB_HOST}" -p "${DB_PORT}" -U "${DB_USER}" -d "${DB_NAME}" \
|
||||||
|
-f "${APP_DIR}/server/schema/postgresql/createdb.sql" 2>/dev/null || true
|
||||||
|
}
|
||||||
|
|
||||||
|
update_ds_settings() {
|
||||||
|
echo "Updating DocumentServer settings..."
|
||||||
|
local JSON="${CONF_DIR}/local.json"
|
||||||
|
|
||||||
|
# Create local.json with all settings
|
||||||
|
cat > "${JSON}" << EOF
|
||||||
|
{
|
||||||
|
"services": {
|
||||||
|
"CoAuthoring": {
|
||||||
|
"sql": {
|
||||||
|
"type": "${DB_TYPE}",
|
||||||
|
"dbHost": "${DB_HOST}",
|
||||||
|
"dbPort": "${DB_PORT}",
|
||||||
|
"dbName": "${DB_NAME}",
|
||||||
|
"dbUser": "${DB_USER}",
|
||||||
|
"dbPass": "${DB_PWD}"
|
||||||
|
},
|
||||||
|
"redis": {
|
||||||
|
"host": "${REDIS_SERVER_HOST}",
|
||||||
|
"port": ${REDIS_SERVER_PORT}
|
||||||
|
},
|
||||||
|
"pubsub": {
|
||||||
|
"maxNumberOfReceivers": "infinity"
|
||||||
|
},
|
||||||
|
"token": {
|
||||||
|
"enable": {
|
||||||
|
"request": {
|
||||||
|
"inbox": ${JWT_ENABLED},
|
||||||
|
"outbox": ${JWT_ENABLED}
|
||||||
|
},
|
||||||
|
"browser": ${JWT_ENABLED}
|
||||||
|
},
|
||||||
|
"inbox": {
|
||||||
|
"header": "${JWT_HEADER}",
|
||||||
|
"inBody": ${JWT_IN_BODY}
|
||||||
|
},
|
||||||
|
"outbox": {
|
||||||
|
"header": "${JWT_HEADER}",
|
||||||
|
"inBody": ${JWT_IN_BODY}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"secret": {
|
||||||
|
"inbox": {
|
||||||
|
"string": "${JWT_SECRET}"
|
||||||
|
},
|
||||||
|
"outbox": {
|
||||||
|
"string": "${JWT_SECRET}"
|
||||||
|
},
|
||||||
|
"session": {
|
||||||
|
"string": "${JWT_SECRET}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"rabbitmq": {
|
||||||
|
"url": "${AMQP_SERVER_PROTO}://${AMQP_SERVER_USER}:${AMQP_SERVER_PWD}@${AMQP_SERVER_HOST}:${AMQP_SERVER_PORT}"
|
||||||
|
},
|
||||||
|
"wopi": {
|
||||||
|
"enable": ${WOPI_ENABLED}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
chown ds:ds "${JSON}"
|
||||||
|
chmod 644 "${JSON}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# ============================================
|
||||||
|
# MAIN STARTUP SEQUENCE
|
||||||
|
# ============================================
|
||||||
|
|
||||||
|
echo "============================================"
|
||||||
|
echo "ONLYOFFICE DocumentServer Startup"
|
||||||
|
echo "============================================"
|
||||||
|
echo "Database: ${DB_HOST}:${DB_PORT}/${DB_NAME}"
|
||||||
|
echo "Redis: ${REDIS_SERVER_HOST}:${REDIS_SERVER_PORT}"
|
||||||
|
echo "RabbitMQ: ${AMQP_SERVER_HOST}:${AMQP_SERVER_PORT}"
|
||||||
|
echo "JWT Enabled: ${JWT_ENABLED}"
|
||||||
|
echo "============================================"
|
||||||
|
|
||||||
|
# Create log directories
|
||||||
|
for i in converter docservice metrics adminpanel; do
|
||||||
|
mkdir -p "$DS_LOG_DIR/$i" && touch "$DS_LOG_DIR/$i"/{out,err}.log
|
||||||
|
done
|
||||||
|
mkdir -p "${DS_LOG_DIR}-example" && touch "${DS_LOG_DIR}-example"/{out,err}.log
|
||||||
|
|
||||||
|
# Create app directories
|
||||||
|
for i in ${DS_LIB_DIR}/App_Data/cache/files ${DS_LIB_DIR}/App_Data/docbuilder ${DS_LIB_DIR}-example/files; do
|
||||||
|
mkdir -p "$i"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Create data directory
|
||||||
|
mkdir -p "${DATA_DIR}"
|
||||||
|
mkdir -p "${PRIVATE_DATA_DIR}"
|
||||||
|
|
||||||
|
# Set permissions
|
||||||
|
chown ds:ds "${DATA_DIR}"
|
||||||
|
for i in ${DS_LOG_DIR} ${DS_LOG_DIR}-example ${LIB_DIR}; do
|
||||||
|
chown -R ds:ds "$i"
|
||||||
|
chmod -R 755 "$i"
|
||||||
|
done
|
||||||
|
|
||||||
|
# Array to track local services that need to be started
|
||||||
|
LOCAL_SERVICES=()
|
||||||
|
|
||||||
|
# Handle database
|
||||||
|
if [ "${DB_HOST}" = "localhost" ]; then
|
||||||
|
echo "Starting local PostgreSQL..."
|
||||||
|
chown -R postgres:postgres ${PG_ROOT}
|
||||||
|
chmod -R 700 ${PG_ROOT}
|
||||||
|
|
||||||
|
if [ ! -d "${PGDATA}" ]; then
|
||||||
|
create_postgresql_cluster
|
||||||
|
PG_NEW_CLUSTER=true
|
||||||
|
fi
|
||||||
|
LOCAL_SERVICES+=("postgresql")
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Handle RabbitMQ
|
||||||
|
if [ "${AMQP_SERVER_HOST}" = "localhost" ]; then
|
||||||
|
echo "Starting local RabbitMQ..."
|
||||||
|
chown -R rabbitmq:rabbitmq ${RABBITMQ_DATA}
|
||||||
|
chmod -R go=rX,u=rwX ${RABBITMQ_DATA}
|
||||||
|
if [ -f ${RABBITMQ_DATA}/.erlang.cookie ]; then
|
||||||
|
chmod 400 ${RABBITMQ_DATA}/.erlang.cookie
|
||||||
|
fi
|
||||||
|
rm -rf /var/run/rabbitmq
|
||||||
|
LOCAL_SERVICES+=("rabbitmq-server")
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Handle Redis
|
||||||
|
if [ "${REDIS_ENABLED}" = "true" ] && [ "${REDIS_SERVER_HOST}" = "localhost" ]; then
|
||||||
|
echo "Starting local Redis..."
|
||||||
|
chown -R redis:redis ${REDIS_DATA}
|
||||||
|
chmod -R 750 ${REDIS_DATA}
|
||||||
|
LOCAL_SERVICES+=("redis-server")
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Start local services
|
||||||
|
for i in ${LOCAL_SERVICES[@]}; do
|
||||||
|
echo "Starting service: $i"
|
||||||
|
service $i start
|
||||||
|
done
|
||||||
|
|
||||||
|
# Wait for and initialize database
|
||||||
|
if [ "${DB_HOST}" = "localhost" ]; then
|
||||||
|
sleep 3
|
||||||
|
if [ "${PG_NEW_CLUSTER}" = "true" ]; then
|
||||||
|
create_postgresql_db
|
||||||
|
create_postgresql_tbl
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
waiting_for_db
|
||||||
|
# Check if tables exist, if not create them
|
||||||
|
PGPASSWORD="${DB_PWD}" psql -h "${DB_HOST}" -p "${DB_PORT}" -U "${DB_USER}" -d "${DB_NAME}" \
|
||||||
|
-c "SELECT 1 FROM doc_changes LIMIT 1" 2>/dev/null || create_postgresql_tbl
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Wait for other services
|
||||||
|
waiting_for_amqp
|
||||||
|
if [ "${REDIS_ENABLED}" = "true" ]; then
|
||||||
|
waiting_for_redis
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Update DocumentServer configuration
|
||||||
|
update_ds_settings
|
||||||
|
|
||||||
|
# Configure nginx
|
||||||
|
echo "Configuring Nginx..."
|
||||||
|
NGINX_ONLYOFFICE_PATH="${CONF_DIR}/nginx"
|
||||||
|
NGINX_ONLYOFFICE_CONF="${NGINX_ONLYOFFICE_PATH}/ds.conf"
|
||||||
|
ln -sf ${NGINX_ONLYOFFICE_PATH}/ds.conf.tmpl ${NGINX_ONLYOFFICE_CONF}
|
||||||
|
|
||||||
|
# Install plugins if enabled
|
||||||
|
if [ "${PLUGINS_ENABLED}" = "true" ]; then
|
||||||
|
echo "Installing plugins..."
|
||||||
|
start_process documentserver-pluginsmanager.sh -r false --update=\"${APP_DIR}/sdkjs-plugins/plugin-list-default.json\" >/dev/null 2>&1 || true
|
||||||
|
echo "Plugins installed."
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Start supervisor (manages DocService, Converter, etc.)
|
||||||
|
echo "Starting Supervisor..."
|
||||||
|
service supervisor start
|
||||||
|
|
||||||
|
# Start cron for log rotation
|
||||||
|
service cron start
|
||||||
|
|
||||||
|
# Flush cache
|
||||||
|
start_process documentserver-flush-cache.sh -r false 2>/dev/null || true
|
||||||
|
|
||||||
|
# Start nginx
|
||||||
|
echo "Starting Nginx..."
|
||||||
|
service nginx start
|
||||||
|
|
||||||
|
# Generate fonts if enabled
|
||||||
|
if [ "${GENERATE_FONTS}" = "true" ]; then
|
||||||
|
echo "Generating fonts..."
|
||||||
|
start_process documentserver-generate-allfonts.sh false >/dev/null 2>&1 || true
|
||||||
|
echo "Fonts generated."
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Compress static files
|
||||||
|
start_process documentserver-static-gzip.sh false >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
echo "============================================"
|
||||||
|
echo "ONLYOFFICE DocumentServer is ready!"
|
||||||
|
echo "Access at: http://localhost"
|
||||||
|
if [ "${JWT_ENABLED}" = "true" ]; then
|
||||||
|
echo "JWT Secret: ${JWT_SECRET}"
|
||||||
|
fi
|
||||||
|
echo "============================================"
|
||||||
|
|
||||||
|
# Keep container running and tail logs
|
||||||
|
exec tail -F ${DS_LOG_DIR}/docservice/out.log ${DS_LOG_DIR}/converter/out.log 2>/dev/null
|
||||||
2
sdkjs
2
sdkjs
Submodule sdkjs updated: 649a4b57ba...3afdbeacca
2
server
2
server
Submodule server updated: 0ebd3b07b8...dabf8839e8
2
web-apps
2
web-apps
Submodule web-apps updated: 06bc5a77e9...888dd4ae4e
Reference in New Issue
Block a user