From 145b76b3d59c0f8927a594ec77f0b1764f66470b Mon Sep 17 00:00:00 2001 From: Paul Healy Date: Sat, 12 Mar 2022 14:03:01 +0000 Subject: [PATCH] revbump to 1.7.30 add doc on logging configuration, openrc... etc --- README.md | 34 +++++++++++++++++++++++++++++++++- bin/opengrok-docker | 2 +- etc/opengrok.conf | 2 +- 3 files changed, 35 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 4e416e9..32c7e34 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # opengrok-docker -Driver program to manage a containerised opengrok appliance +Driver program to manage a containerised opengrok appliance. ## Configuration @@ -27,6 +27,9 @@ $ opengrok-docker stop $ opengrok-docker delete ``` +The pull and create should only be done once per version bump. +After that the container can be started and stopped as required. + ## Upgrade 1. opengrok-docker stop @@ -35,6 +38,35 @@ $ opengrok-docker delete 4. opengrok-docker create 5. opengrok-docker start +Optional - to remove an old container and/or image: + +6. docker rm opengrok-1.7.17 +7. docker rmi opengrok/docker:1.7.17 + +## OpenRC + +To have the container start automatically: + +``` +rc-config add opengrok +``` + +## Logging + +The default docker "json-file" logging driver does *not* do log rotation. + +To select the "local" driver, with a max file size of 10MB and four files, add this to `/etc/docker/daemon.json`: + +```json +{ + "log-driver": "local", + "log-opts": { + "max-size": "10m", + "max-file": "4" + } +} +``` + ## References 1. https://github.com/oracle/opengrok/tree/master/docker diff --git a/bin/opengrok-docker b/bin/opengrok-docker index d291d60..e7a4764 100755 --- a/bin/opengrok-docker +++ b/bin/opengrok-docker @@ -1,6 +1,6 @@ #!/bin/bash -opengrok_version=${opengrok_version:-1.7.21} +opengrok_version=${opengrok_version:-1.7.30} opengrok_sync=${opengrok_sync:-0} opengrok_nomirror=${opengrok_nomirror:-1} diff --git a/etc/opengrok.conf b/etc/opengrok.conf index 9c71cf8..e530fda 100644 --- a/etc/opengrok.conf +++ b/etc/opengrok.conf @@ -1,6 +1,6 @@ # /etc/opengrok.conf: configuration for opengrok-docker -#opengrok_version=1.7.21 +#opengrok_version=1.7.30 #opengrok_sync=0 #opengrok_nomirror=1