Skip to content

Commit 65867eb

Browse files
committed
Merge branch 'develop'
2 parents 113df1f + 9f317f0 commit 65867eb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+567
-405
lines changed

.github/workflows/backend-tests.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,8 @@ jobs:
3030
- name: Install all dependencies and symlink for ep_etherpad-lite
3131
run: src/bin/installDeps.sh
3232

33-
# configures some settings and runs npm run test
3433
- name: Run the backend tests
35-
run: src/tests/frontend/travis/runnerBackend.sh
34+
run: cd src && npm test
3635

3736
withplugins:
3837
# run on pushes to any branch
@@ -84,6 +83,5 @@ jobs:
8483
- name: Install all dependencies and symlink for ep_etherpad-lite
8584
run: src/bin/installDeps.sh
8685

87-
# configures some settings and runs npm run test
8886
- name: Run the backend tests
89-
run: src/tests/frontend/travis/runnerBackend.sh
87+
run: cd src && npm test

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
- "src/bin/installDeps.sh"
6565
- "cd src && npm install && cd -"
6666
script:
67-
- "src/tests/frontend/travis/runnerBackend.sh"
67+
- "cd src && npm test"
6868
- name: "Test the Dockerfile"
6969
install:
7070
- "cd src && npm install && cd -"
@@ -107,7 +107,7 @@ jobs:
107107
- *install_plugins
108108
- "cd src && npm install && cd -"
109109
script:
110-
- "src/tests/frontend/travis/runnerBackend.sh"
110+
- "cd src && npm test"
111111
- name: "Test the Dockerfile"
112112
install:
113113
- "cd src && npm install && cd -"

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
# 1.8.9
2+
3+
### Notable fixes
4+
5+
* Fixed HTTP 400 error when importing via the UI.
6+
* Fixed "Error: spawn npm ENOENT" crash on startup in Windows.
7+
8+
### Notable enhancements
9+
10+
* Removed some unnecessary arrow key handling logic.
11+
* Dependency updates.
12+
113
# 1.8.8
214

315
### Security patches

Dockerfile

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,22 @@ LABEL maintainer="Etherpad team, https://github.com/ether/etherpad-lite"
1515
# ETHERPAD_PLUGINS="ep_codepad ep_author_neat"
1616
ARG ETHERPAD_PLUGINS=
1717

18+
# Control whether abiword will be installed, enabling exports to DOC/PDF/ODT formats.
19+
# By default, it is not installed.
20+
# If given any value, abiword will be installed.
21+
#
22+
# EXAMPLE:
23+
# INSTALL_ABIWORD=true
24+
ARG INSTALL_ABIWORD=
25+
26+
# Control whether libreoffice will be installed, enabling exports to DOC/PDF/ODT formats.
27+
# By default, it is not installed.
28+
# If given any value, libreoffice will be installed.
29+
#
30+
# EXAMPLE:
31+
# INSTALL_LIBREOFFICE=true
32+
ARG INSTALL_SOFFICE=
33+
1834
# By default, Etherpad container is built and run in "production" mode. This is
1935
# leaner (development dependencies are not installed) and runs faster (among
2036
# other things, assets are minified & compressed).
@@ -28,6 +44,13 @@ RUN useradd --uid 5001 --create-home etherpad
2844

2945
RUN mkdir /opt/etherpad-lite && chown etherpad:0 /opt/etherpad-lite
3046

47+
# install abiword for DOC/PDF/ODT export
48+
RUN [ -z "${INSTALL_ABIWORD}" ] || (apt update && apt -y install abiword && apt clean && rm -rf /var/lib/apt/lists/*)
49+
50+
# install libreoffice for DOC/PDF/ODT export
51+
# the mkdir is needed for configuration of openjdk-11-jre-headless, see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199
52+
RUN [ -z "${INSTALL_SOFFICE}" ] || (apt update && mkdir -p /usr/share/man/man1 && apt -y install libreoffice && apt clean && rm -rf /var/lib/apt/lists/*)
53+
3154
USER etherpad
3255

3356
WORKDIR /opt/etherpad-lite
@@ -51,4 +74,4 @@ COPY --chown=etherpad:0 ./settings.json.docker /opt/etherpad-lite/settings.json
5174
RUN chmod -R g=u .
5275

5376
EXPOSE 9001
54-
CMD ["node", "--experimental-worker", "node_modules/ep_etherpad-lite/node/server.js"]
77+
CMD ["node", "--experimental-worker", "src/node/server.js"]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ Update to the latest version with `git pull origin`, then run
6666

6767
If cloning to a subdirectory within another project, you may need to do the following:
6868

69-
1. Start the server manually (e.g. `node/node_modules/ep_etherpad-lite/node/server.js`)
69+
1. Start the server manually (e.g. `node src/node/server.js`)
7070
2. Edit the db `filename` in `settings.json` to the relative directory with the file (e.g. `application/lib/etherpad-lite/var/dirty.db`)
7171
3. Add auto-generated files to the main project `.gitignore`
7272

doc/docker.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,30 @@ The variable value has to be a space separated, double quoted list of plugin nam
2929

3030
Some plugins will need personalized settings. Just refer to the previous section, and include them in your custom `settings.json.docker`.
3131

32+
### Rebuilding including export functionality for DOC/PDF/ODT
33+
34+
If you want to be able to export your pads to DOC/PDF/ODT files, you can install
35+
either Abiword or Libreoffice via setting a build variable.
36+
37+
#### Via Abiword
38+
39+
For installing Abiword, set the `INSTALL_ABIWORD` build variable to any value.
40+
41+
Also, you will need to configure the path to the abiword executable
42+
via setting the `abiword` property in `<BASEDIR>/settings.json.docker` to
43+
`/usr/bin/abiword` or via setting the environment variable `ABIWORD` to
44+
`/usr/bin/abiword`.
45+
46+
#### Via Libreoffice
47+
48+
For installing Libreoffice instead, set the `INSTALL_SOFFICE` build variable
49+
to any value.
50+
51+
Also, you will need to configure the path to the libreoffice executable
52+
via setting the `soffice` property in `<BASEDIR>/settings.json.docker` to
53+
`/usr/bin/soffice` or via setting the environment variable `SOFFICE` to
54+
`/usr/bin/soffice`.
55+
3256
### Examples
3357

3458
Build a Docker image from the currently checked-out code:
@@ -168,8 +192,8 @@ For the editor container, you can also make it full width by adding `full-width-
168192
| `IMPORT_MAX_FILE_SIZE` | maximum allowed file size when importing a pad, in bytes. | `52428800` (50 MB) |
169193
| `IMPORT_EXPORT_MAX_REQ_PER_IP` | maximum number of import/export calls per IP. | `10` |
170194
| `IMPORT_EXPORT_RATE_LIMIT_WINDOW` | the call rate for import/export requests will be estimated in this time window (in milliseconds) | `90000` |
171-
| `COMMIT_RATE_LIMIT_DURATION` | duration of the rate limit window for commits by individual users/IPs (in seconds) | `1` |
172-
| `COMMIT_RATE_LIMIT_POINTS` | maximum number of changes per IP to allow during the rate limit window | `10` |
195+
| `COMMIT_RATE_LIMIT_DURATION` | duration of the rate limit window for commits by individual users/IPs (in seconds) | `1` |
196+
| `COMMIT_RATE_LIMIT_POINTS` | maximum number of changes per IP to allow during the rate limit window | `10` |
173197
| `SUPPRESS_ERRORS_IN_PAD_TEXT` | Should we suppress errors from being visible in the default Pad Text? | `false` |
174198
| `REQUIRE_SESSION` | If this option is enabled, a user must have a session to access pads. This effectively allows only group pads to be accessed. | `false` |
175199
| `EDIT_ONLY` | Users may edit pads but not create new ones. Pad creation is only via the API. This applies both to group pads and regular pads. | `false` |

src/bin/buildForWindows.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ fatal() { error "$@"; exit 1; }
77
is_cmd() { command -v "$@" >/dev/null 2>&1; }
88

99
# Move to the folder where ep-lite is installed
10-
cd "$(dirname "$0")"/..
10+
cd "$(cd "${0%/*}" && pwd -P)/../.."
1111

1212
# Is wget installed?
1313
is_cmd wget || fatal "Please install wget"
@@ -54,7 +54,7 @@ rm -rf "$TMP_FOLDER"/src/node_modules/nodemailer/node_modules/mailcomposer/node_
5454

5555
log "create the zip..."
5656
cd "$TMP_FOLDER"
57-
zip -9 -r "$START_FOLDER"/etherpad-lite-win.zip ./*
57+
zip -9 -r "$START_FOLDER"/etherpad-lite-win.zip ./* -x var
5858

5959
log "clean up..."
6060
rm -rf "$TMP_FOLDER"

src/bin/cleanRun.sh

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ rm -rf src/node_modules
3434
src/bin/installDeps.sh "$@" || exit 1
3535

3636
#Move to the node folder and start
37-
echo "Started Etherpad..."
37+
echo "Starting Etherpad..."
3838

39-
SCRIPTPATH=$(pwd -P)
40-
node $(compute_node_args) "${SCRIPTPATH}/node_modules/ep_etherpad-lite/node/server.js" "$@"
39+
exec node $(compute_node_args) src/node/server.js "$@"

src/bin/deb-src/sysroot/etc/init/etherpad.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ end script
2020

2121
script
2222
cd $EPHOME/
23-
exec su -s /bin/sh -c 'exec "$0" "$@"' $EPUSER -- node node_modules/ep_etherpad-lite/node/server.js \
23+
exec su -s /bin/sh -c 'exec "$0" "$@"' $EPUSER -- node src/node/server.js \
2424
>> $EPLOGS/access.log \
2525
2>> $EPLOGS/error.log
2626
echo "Etherpad is running on http://localhost:9001 - To change settings edit /opt/etherpad/settings.json"

src/bin/debugRun.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ echo "Open 'chrome://inspect' on Chrome to start debugging."
1616

1717
# Use 0.0.0.0 to allow external connections to the debugger
1818
# (ex: running Etherpad on a docker container). Use default port # (9229)
19-
node $(compute_node_args) --inspect=0.0.0.0:9229 node_modules/ep_etherpad-lite/node/server.js "$@"
19+
exec node $(compute_node_args) --inspect=0.0.0.0:9229 src/node/server.js "$@"

0 commit comments

Comments
 (0)