-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
73 lines (52 loc) · 2.62 KB
/
Copy pathDockerfile
File metadata and controls
73 lines (52 loc) · 2.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
FROM ubuntu:24.04
# docker build -t jheinecke/metamorphosed:4.6.1 .
# grype jheinecke/metamorphosed:4.6.1 --only-fixed | egrep "High|Criti"
# trivy image jheinecke/metamorphosed:4.6.1 --scanners vuln --timeout 15m --severity MEDIUM,HIGH,CRITICAL --ignore-unfixed
# edit mode
# docker run --rm -d -t --name metamorphosed -p 4567:4567 -v <absolute/path/to/datadir>:/data --env AMRFILE=testamr.txt jheinecke/metamorphosed:4.6.1
# comparison (the directory in COMPAREWITH must be /data ! (internal path of docker image))
# docker run --rm -d -t --name metamorphosed -p 4567:4567 -v <absolute/path/to/datadir>:/data --env AMRFILE=testamr.txt --env COMPAREWITH="--compare /data/testamr.txt.2" jheinecke/metamorphosed:4.6.1
LABEL org.label-schema.name="metAMoRphosED"
LABEL org.label-schema.description="An Abstract Meaning Representations editor"
LABEL org.label-schema.summary="AMR annotation/validation/comparison"
LABEL org.label-schema.vendor="Johannes Heinecke <johannes.heinecke@orange.com>"
LABEL org.label-schema.version="${DOCKER_VERSION}"
LABEL org.label-schema.schema_version="RC1"
RUN apt-get update \
&& apt-get -y upgrade \
&& apt-get -y install graphviz python3-minimal python3-pip python3.12-venv git wget libffi-dev \
&& apt-get clean
RUN python3 -m venv /opt/venv
WORKDIR /wikidata
COPY requirements.txt .
RUN . /opt/venv/bin/activate && pip --no-cache-dir install -r requirements.txt
# public
RUN echo a
RUN git clone https://github.com/Orange-OpenSource/metamorphosed.git
# developping
#WORKDIR /wikidata/metamorphosed
#COPY metamorphosed_server.py .
#COPY metamorphosed metamorphosed
#COPY propbank-frames/frames propbank-frames/frames
WORKDIR /wikidata/metamorphosed
RUN cd propbank-frames/frames; \
git checkout ad2bafa4c9c9c58cc1bc89; \
wget https://raw.githubusercontent.com/propbank/propbank-frames/development/frames/AMR-UMR-91-rolesets.xml; \
cd ../..
RUN . /opt/venv/bin/activate && ./metamorphosed/installJQ.py
EXPOSE 4567
ENV AMRLIB_URL=
ENV PROPERTY_LABELS=
ENV QUAL_LABELS=
ENV NON_FILE_OPTIONS=
#HEALTHCHECK --interval=60s --timeout=3s --retries=1 \
# CMD curl --silent --fail --noproxy '*' http://localhost:3500/status | grep '"status": "ok"' || exit 1
#CMD . /opt/venv/bin/activate && exec ./metamorphosed_server.py \
# --pbframes ./propbank-frames/frames/ \
# --reifications ./metamorphosed/data/reification-table.txt \
# -f /data/$AMRFILE $COMPAREWITH
CMD . /opt/venv/bin/activate && exec ./metamorphosed_server.py \
--pbframes ./propbank-frames/frames/ \
--reifications ./metamorphosed/data/reification-table.txt \
$NON_FILE_OPTIONS \
-f None --dockerargs /data $AMRFILE $COMPAREWITH