Skip to content
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

Dockerfile update #96

Merged
merged 4 commits into from
Feb 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# Patch and build Olena from Git, then
# Install OCR-D wrapper for binarization
FROM ocrd/core
FROM docker.io/ocrd/core:v2.62.0 AS base
ARG VCS_REF
ARG BUILD_DATE
bertsky marked this conversation as resolved.
Show resolved Hide resolved
LABEL \
maintainer="https://github.com/OCR-D/ocrd_olena/issues" \
org.label-schema.vcs-ref=$VCS_REF \
org.label-schema.vcs-url="https://github.com/OCR-D/ocrd_olena" \
org.label-schema.build-date=$BUILD_DATE

MAINTAINER OCR-D

Expand All @@ -26,7 +33,3 @@ RUN apt-get update && \

WORKDIR /data
VOLUME /data

#ENTRYPOINT ["/usr/bin/ocrd-olena-binarize"]
#CMD ["--help"]
CMD ["/usr/bin/ocrd-olena-binarize", "--help"]
10 changes: 8 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,14 @@ clean:
$(RM) -r test/assets

docker: build-olena.dockerfile Dockerfile
docker build -t $(DOCKER_TAG):build-olena -f build-olena.dockerfile .
docker build -t $(DOCKER_TAG) .
docker build \
--build-arg VCS_REF=$$(git rev-parse --short HEAD) \
--build-arg BUILD_DATE=$$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
-t $(DOCKER_TAG):build-olena -f build-olena.dockerfile .
docker build \
--build-arg VCS_REF=$$(git rev-parse --short HEAD) \
--build-arg BUILD_DATE=$$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
-t $(DOCKER_TAG) .

.PHONY: build-olena clean-olena deps deps-ubuntu help install install-tools test clean docker

Expand Down
7 changes: 7 additions & 0 deletions build-olena.dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Patch and build Olena from Git
FROM ubuntu:18.04
ARG VCS_REF
ARG BUILD_DATE
LABEL \
maintainer="https://github.com/OCR-D/ocrd_olena/issues" \
org.label-schema.vcs-ref=$VCS_REF \
org.label-schema.vcs-url="https://github.com/OCR-D/ocrd_olena" \
org.label-schema.build-date=$BUILD_DATE

MAINTAINER OCR-D

Expand Down