-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Update couchdb, add new couchdb-nouveau fulltext search addon #17633
Update couchdb, add new couchdb-nouveau fulltext search addon #17633
Conversation
This comment has been minimized.
This comment has been minimized.
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.
-1
This fails for me at least:
Starting buildx build at Fri Sep 27 03:50:08 EDT 2024...
[+] Building 3.1s (6/6) FINISHED docker-container:apache-couchdb
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 4.46kB 0.0s
=> CANCELED [linux/arm64 internal] load metadata for docker.io/library/debian:bullseye-slim 3.0s
=> CANCELED [linux/amd64 internal] load metadata for docker.io/library/debian:bullseye-slim 3.0s
=> ERROR [linux/s390x internal] load metadata for docker.io/library/debian:bullseye-slim 3.0s
=> ERROR [linux/ppc64le internal] load metadata for docker.io/library/debian:bullseye-slim 3.0s
=> [auth] library/debian:pull token for registry-1.docker.io 0.0s
------
> [linux/s390x internal] load metadata for docker.io/library/debian:bullseye-slim:
------
------
> [linux/ppc64le internal] load metadata for docker.io/library/debian:bullseye-slim:
------
Dockerfile:13
--------------------
11 | # the License.
12 |
13 | >>> FROM debian:bullseye-slim
14 |
15 | LABEL maintainer="CouchDB Developers dev@couchdb.apache.org"
--------------------
ERROR: failed to solve: debian:bullseye-slim: failed to resolve source metadata for docker.io/library/debian:bullseye-slim: no match for platform in manifest: not found
fix incoming shortly |
This comment has been minimized.
This comment has been minimized.
From the CI:
Debian Bullseye is officially in LTS now, so the set of supported architectures is limited and you'll need to either drop the now-unsupported ones or update to Bookworm. I think you'll also want to remove 3.2, right? (I understand it's EOL now?) As a reminder, removing tags here will remove them from the "Supported" section on the Hub readme (and will prevent us from spending cycles rebuilding them on the official build servers), but the tags will still be available to users who want them. (See https://github.com/docker-library/official-images#library-definition-files for more detail on this.) Also, unfortunately we won't likely accept nouveau as a new image (new repo namespace) -- I would suggest using a tag naming scheme like |
@tianon Thank you for your guidance. We'll use bookworm for the base, remove 3.2 and use a tagging scheme for nouveau |
Nouveau needs a Java runtime environment and CouchDB needs an Erlang runtime environment, so stacking them on top of each other does not make too much sense. The other points I have addressed with the latest commit. Am I missing anything? |
This comment has been minimized.
This comment has been minimized.
OH! does the CI error mean we have to bump 3.3.3 to bookworm as well? Sorry if I misunderstood that. Fix incoming shortly |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
finally, all checks green ✅✅✅ thanks for the help! |
One comment for change and a few others for thought: I don't know what the |
@yosifkit thanks for the additional notes. We’re happy to address those in future releases unless anyone here thinks these are showstoppers? Nouveau is marked as a beta feature for this release. We’d love to get the new CouchDB release onto the official library. If the new Nouveau image is holding that up, we can also split this out into a separate PR. |
I guess they are fine this time. It will make the nouveau image a little bit larger (20 MB or more). Something to consider for later: are any of the other Docker official images a suitable base instead of |
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.
Sorry, 🙇 one more thing and this is a blocker for me.
RUN chown -R nouveau:nouveau /opt/nouveau
<missing> About a minute ago RUN /bin/sh -c chown -R nouveau:nouveau /opt… 38.5MB buildkit.dockerfile.v0
This chown
layer is inflating the image size. Because this is changing ownership of files from an earlier layer, there is now an extra copy of everything in /opt/nouveau
for this chown
layer. Any permissions (or mode) changes need to be done in the same layer in which the files originate.
If you'd like to open a separate PR that is just the couchdb bump I can merge that while we continue iterating here for couchdb:*-nouveau
.
@yosifkit there you go, threw in the cleanup as well ✌️ |
This comment has been minimized.
This comment has been minimized.
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.
+1 from me
For commit on 1c0ff3713acf5f5cb2c0dc0229dce3325557bb4f on https://github.com/apache/couchdb-docker
Used buildx to push 3.4.1
, 3.4,
3and
latest` to https://hub.docker.com/repository/docker/apache/couchdb/tags
@big-r81 had noticed we missed another cleanup and we just merged it fix: apache/couchdb-docker#270 |
+1, anything else to get this merged? :) |
Diff for efa4407:diff --git a/_bashbrew-cat b/_bashbrew-cat
index 46b25ab..27fe25e 100644
--- a/_bashbrew-cat
+++ b/_bashbrew-cat
@@ -1,11 +1,16 @@
Maintainers: Joan Touzet <wohali@apache.org> (@wohali), Jan Lehnardt <jan@apache.org> (@janl), Nick Vatamaniuc (@nickva)
GitRepo: https://github.com/apache/couchdb-docker
GitFetch: refs/heads/main
-GitCommit: 58910ed097489dc588b2a87592406f8faa1bdadf
+GitCommit: e748fc4a483c1a651758df4900258701570d2533
-Tags: 3.2.3, 3.2
-Directory: 3.2.3
-
-Tags: latest, 3.3.3, 3.3, 3
+Tags: 3.3.3, 3.3
Architectures: amd64, arm64v8, ppc64le, s390x
Directory: 3.3.3
+
+Tags: 3.4.1-nouveau, 3.4-nouveau, 3-nouveau
+Architectures: amd64, arm64v8, s390x
+Directory: 3.4.1-nouveau
+
+Tags: latest, 3.4.1, 3.4, 3
+Architectures: amd64, arm64v8, s390x
+Directory: 3.4.1
diff --git a/_bashbrew-list b/_bashbrew-list
index 3457842..a1e649e 100644
--- a/_bashbrew-list
+++ b/_bashbrew-list
@@ -1,6 +1,9 @@
couchdb:3
-couchdb:3.2
-couchdb:3.2.3
+couchdb:3-nouveau
couchdb:3.3
couchdb:3.3.3
+couchdb:3.4
+couchdb:3.4-nouveau
+couchdb:3.4.1
+couchdb:3.4.1-nouveau
couchdb:latest
diff --git a/_bashbrew-list-build-order b/_bashbrew-list-build-order
index 66a11cc..833251e 100644
--- a/_bashbrew-list-build-order
+++ b/_bashbrew-list-build-order
@@ -1,2 +1,3 @@
couchdb:3
-couchdb:3.2
+couchdb:3-nouveau
+couchdb:3.3
diff --git a/couchdb_3.2/Dockerfile b/couchdb_3-nouveau/Dockerfile
similarity index 37%
copy from couchdb_3.2/Dockerfile
copy to couchdb_3-nouveau/Dockerfile
index d1d4d4f..ffcb96b 100644
--- a/couchdb_3.2/Dockerfile
+++ b/couchdb_3-nouveau/Dockerfile
@@ -10,12 +10,12 @@
# License for the specific language governing permissions and limitations under
# the License.
-FROM debian:bullseye-slim
+FROM debian:bookworm-slim
LABEL maintainer="CouchDB Developers dev@couchdb.apache.org"
# Add CouchDB user account to make sure the IDs are assigned consistently
-RUN groupadd -g 5984 -r couchdb && useradd -u 5984 -d /opt/couchdb -g couchdb couchdb
+RUN groupadd -g 5984 -r nouveau && useradd -u 5984 -d /opt/nouveau -g nouveau nouveau
# be sure GPG and apt-transport-https are available and functional
RUN set -ex; \
@@ -28,6 +28,14 @@ RUN set -ex; \
; \
rm -rf /var/lib/apt/lists/*
+# Nouveau wants a JRE/JDK
+RUN set -ex; \
+ apt-get update; \
+ apt-get install -y --no-install-recommends \
+ openjdk-17-jre-headless \
+ ; \
+ rm -rf /var/lib/apt/lists/*
+
# grab tini for signal handling and zombie reaping
# see https://github.com/apache/couchdb-docker/pull/28#discussion_r141112407
RUN set -eux; \
@@ -37,9 +45,10 @@ RUN set -eux; \
tini --version
# http://docs.couchdb.org/en/latest/install/unix.html#installing-the-apache-couchdb-packages
-ENV GPG_COUCH_KEY \
# gpg: rsa8192 205-01-19 The Apache Software Foundation (Package repository signing key) <root@apache.org>
- 390EF70BB1EA12B2773962950EE62FB37A00258D
+
+ENV GPG_COUCH_KEY 390EF70BB1EA12B2773962950EE62FB37A00258D
+
RUN set -eux; \
apt-get update; \
apt-get install -y curl; \
@@ -53,52 +62,27 @@ RUN set -eux; \
apt purge -y --autoremove curl; \
rm -rf /var/lib/apt/lists/*
-ENV COUCHDB_VERSION 3.2.3
-
RUN . /etc/os-release; \
- echo "deb [signed-by=/usr/share/keyrings/couchdb-archive-keyring.gpg] https://apache.jfrog.io/artifactory/couchdb-deb/ ${VERSION_CODENAME} main" | \
+ echo "deb [signed-by=/usr/share/keyrings/couchdb-archive-keyring.gpg] https://apache.jfrog.io/artifactory/couchdb-deb/ bookworm main" | \
tee /etc/apt/sources.list.d/couchdb.list >/dev/null
# https://github.com/apache/couchdb-pkg/blob/master/debian/README.Debian
RUN set -eux; \
apt-get update; \
\
- echo "couchdb couchdb/mode select none" | debconf-set-selections; \
-# we DO want recommends this time
- DEBIAN_FRONTEND=noninteractive apt-get install -y --allow-downgrades --allow-remove-essential --allow-change-held-packages \
- couchdb="$COUCHDB_VERSION"~bullseye \
- ; \
-# Undo symlinks to /var/log and /var/lib
- rmdir /var/lib/couchdb /var/log/couchdb; \
- rm /opt/couchdb/data /opt/couchdb/var/log; \
- mkdir -p /opt/couchdb/data /opt/couchdb/var/log; \
- chown couchdb:couchdb /opt/couchdb/data /opt/couchdb/var/log; \
- chmod 777 /opt/couchdb/data /opt/couchdb/var/log; \
-# Remove file that sets logging to a file
- rm /opt/couchdb/etc/default.d/10-filelog.ini; \
-# Check we own everything in /opt/couchdb. Matches the command in dockerfile_entrypoint.sh
- find /opt/couchdb \! \( -user couchdb -group couchdb \) -exec chown -f couchdb:couchdb '{}' +; \
-# Setup directories and permissions for config. Technically these could be 555 and 444 respectively
-# but we keep them as 755 and 644 for consistency with CouchDB defaults and the dockerfile_entrypoint.sh.
- find /opt/couchdb/etc -type d ! -perm 0755 -exec chmod -f 0755 '{}' +; \
- find /opt/couchdb/etc -type f ! -perm 0644 -exec chmod -f 0644 '{}' +; \
-# only local.d needs to be writable for the docker_entrypoint.sh
- chmod -f 0777 /opt/couchdb/etc/local.d; \
-# apt clean-up
- rm -rf /var/lib/apt/lists/*;
+ echo "couchdb-nouveau couchdb-nouveau/enable select false" | debconf-set-selections; \
+ DEBIAN_FRONTEND=noninteractive COUCHDB_NOUVEAU_ENABLE=1 apt-get install -y --allow-downgrades --allow-remove-essential --allow-change-held-packages --no-install-recommends \
+ couchdb-nouveau=3.4.1~bookworm; \
+ rm -rf /var/lib/apt/lists/*; \
+ chown -R nouveau:nouveau /opt/nouveau
-# Add configuration
-COPY --chown=couchdb:couchdb 10-docker-default.ini /opt/couchdb/etc/default.d/
-COPY --chown=couchdb:couchdb vm.args /opt/couchdb/etc/
+COPY --chown=nouveau:nouveau nouveau.yaml /opt/nouveau/etc/nouveau.yaml
-COPY docker-entrypoint.sh /usr/local/bin
-RUN ln -s usr/local/bin/docker-entrypoint.sh /docker-entrypoint.sh # backwards compat
-ENTRYPOINT ["tini", "--", "/docker-entrypoint.sh"]
+VOLUME /opt/nouveau/data
-VOLUME /opt/couchdb/data
+# 5987: Nouveau App
+# 5988: Nouveau Admin
+EXPOSE 5987 5988
-# 5984: Main CouchDB endpoint
-# 4369: Erlang portmap daemon (epmd)
-# 9100: CouchDB cluster communication port
-EXPOSE 5984 4369 9100
-CMD ["/opt/couchdb/bin/couchdb"]
+# TODO: re-add tini
+CMD ["/usr/bin/java", "-server", "-Djava.awt.headless=true", "-Xmx2g", "-jar", "/opt/nouveau/lib/nouveau-1.0-SNAPSHOT.jar", "server", "/opt/nouveau/etc/nouveau.yaml"]
diff --git a/couchdb_3-nouveau/nouveau.yaml b/couchdb_3-nouveau/nouveau.yaml
new file mode 100644
index 0000000..5750942
--- /dev/null
+++ b/couchdb_3-nouveau/nouveau.yaml
@@ -0,0 +1,27 @@
+maxIndexesOpen: 3000
+commitIntervalSeconds: 30
+idleSeconds: 60
+rootDir: ./data/nouveau
+
+logging:
+ level: INFO
+
+server:
+ applicationConnectors:
+ - type: http
+ bindHost: 0.0.0.0
+ port: 5987
+ useDateHeader: false
+ adminConnectors:
+ - type: http
+ bindHost: 0.0.0.0
+ port: 5988
+ useDateHeader: false
+ gzip:
+ includedMethods:
+ - GET
+ - POST
+ requestLog:
+ appenders:
+ - type: console
+ target: stderr
diff --git a/couchdb_3.2/vm.args b/couchdb_3.2/vm.args
deleted file mode 100644
index d606217..0000000
diff --git a/couchdb_3.2/10-docker-default.ini b/couchdb_3.3/10-docker-default.ini
similarity index 100%
rename from couchdb_3.2/10-docker-default.ini
rename to couchdb_3.3/10-docker-default.ini
diff --git a/couchdb_3.2/Dockerfile b/couchdb_3.3/Dockerfile
similarity index 97%
rename from couchdb_3.2/Dockerfile
rename to couchdb_3.3/Dockerfile
index d1d4d4f..6d86dfb 100644
--- a/couchdb_3.2/Dockerfile
+++ b/couchdb_3.3/Dockerfile
@@ -10,7 +10,7 @@
# License for the specific language governing permissions and limitations under
# the License.
-FROM debian:bullseye-slim
+FROM debian:bookworm-slim
LABEL maintainer="CouchDB Developers dev@couchdb.apache.org"
@@ -53,7 +53,7 @@ RUN set -eux; \
apt purge -y --autoremove curl; \
rm -rf /var/lib/apt/lists/*
-ENV COUCHDB_VERSION 3.2.3
+ENV COUCHDB_VERSION 3.3.3
RUN . /etc/os-release; \
echo "deb [signed-by=/usr/share/keyrings/couchdb-archive-keyring.gpg] https://apache.jfrog.io/artifactory/couchdb-deb/ ${VERSION_CODENAME} main" | \
@@ -66,7 +66,7 @@ RUN set -eux; \
echo "couchdb couchdb/mode select none" | debconf-set-selections; \
# we DO want recommends this time
DEBIAN_FRONTEND=noninteractive apt-get install -y --allow-downgrades --allow-remove-essential --allow-change-held-packages \
- couchdb="$COUCHDB_VERSION"~bullseye \
+ couchdb="$COUCHDB_VERSION-1"~bookworm \
; \
# Undo symlinks to /var/log and /var/lib
rmdir /var/lib/couchdb /var/log/couchdb; \
diff --git a/couchdb_3.2/docker-entrypoint.sh b/couchdb_3.3/docker-entrypoint.sh
similarity index 100%
rename from couchdb_3.2/docker-entrypoint.sh
rename to couchdb_3.3/docker-entrypoint.sh
diff --git a/couchdb_3/vm.args b/couchdb_3.3/vm.args
similarity index 100%
copy from couchdb_3/vm.args
copy to couchdb_3.3/vm.args
diff --git a/couchdb_3/Dockerfile b/couchdb_3/Dockerfile
index 16bdf32..2314c8d 100644
--- a/couchdb_3/Dockerfile
+++ b/couchdb_3/Dockerfile
@@ -10,7 +10,7 @@
# License for the specific language governing permissions and limitations under
# the License.
-FROM debian:bullseye-slim
+FROM debian:bookworm-slim
LABEL maintainer="CouchDB Developers dev@couchdb.apache.org"
@@ -53,7 +53,7 @@ RUN set -eux; \
apt purge -y --autoremove curl; \
rm -rf /var/lib/apt/lists/*
-ENV COUCHDB_VERSION 3.3.3
+ENV COUCHDB_VERSION 3.4.1
RUN . /etc/os-release; \
echo "deb [signed-by=/usr/share/keyrings/couchdb-archive-keyring.gpg] https://apache.jfrog.io/artifactory/couchdb-deb/ ${VERSION_CODENAME} main" | \
@@ -66,7 +66,7 @@ RUN set -eux; \
echo "couchdb couchdb/mode select none" | debconf-set-selections; \
# we DO want recommends this time
DEBIAN_FRONTEND=noninteractive apt-get install -y --allow-downgrades --allow-remove-essential --allow-change-held-packages \
- couchdb="$COUCHDB_VERSION"~bullseye \
+ couchdb="$COUCHDB_VERSION"~bookworm \
; \
# Undo symlinks to /var/log and /var/lib
rmdir /var/lib/couchdb /var/log/couchdb; \ Relevant Maintainers: |
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.
+1
Added the corresponding rm -rf /var/lib/apt/lists/*
lines and removed the layer bloating of the separate chown
command.
All is ✅.
You don't need to source It also seems strange to |
No description provided.