Skip to content

Commit

Permalink
Merge pull request #229 from sbs20/staging
Browse files Browse the repository at this point in the history
Docker build / preview crash
  • Loading branch information
sbs20 authored May 2, 2021
2 parents d867052 + 31ab372 commit 4cc56f1
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Builder image. Alpine doesn't have python which is required by node-sass
FROM node:buster AS builder
FROM node:14-buster AS builder
ENV APP_DIR=/app
WORKDIR "$APP_DIR"

Expand All @@ -20,7 +20,7 @@ RUN cd webui \
&& npm run server-build

# production image
FROM node:buster-slim
FROM node:14-buster-slim
ENV APP_DIR=/app
WORKDIR "$APP_DIR"
RUN apt-get update \
Expand Down
8 changes: 6 additions & 2 deletions docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ sudo chmod 666 /var/run/docker.sock
```

Useful commands
```console
```sh
# Build and run
docker build -t scanservjs-image .
docker rm --force scanservjs-container 2> /dev/null
Expand Down Expand Up @@ -82,11 +82,15 @@ docker container restart scanservjs-container
# Maintenance
docker ps -a
docker image prune
docker image rm -f $(docker image ls --filter dangling=true -q)

# Danger
docker image rm -f $(docker image ls -a -q)
```

## Mount map configuration files

```
```sh
docker run -d \
-p 8080:8080 \
-v `pwd`/var/:/app/config/ \
Expand Down
2 changes: 1 addition & 1 deletion server/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion server/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "scanservjs-server",
"version": "2.11.1",
"version": "2.11.2",
"description": "scanservjs is a simple web-based UI for SANE which allows you to share a scanner on a network without the need for drivers or complicated installation. scanserv does not do image conversion or manipulation (beyond the bare minimum necessary for the purposes of browser preview) or OCR.",
"scripts": {
"serve": "nodemon --exec 'vue-cli-service serve'",
Expand Down
2 changes: 1 addition & 1 deletion server/src/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class Api {
if (source.exists()) {
const buffer = source.toBuffer();
const cmds = [...Config.previewPipeline.commands];
if (filters) {
if (filters && filters.length) {
const params = Filters.build(filters, true);
cmds.splice(0, 0, `convert - ${params} tif:-`);
}
Expand Down

0 comments on commit 4cc56f1

Please sign in to comment.