Skip to content

Commit f275077

Browse files
[Update]: use opensource COBOL 4J 1.1.2 (#18)
1 parent e34184c commit f275077

File tree

2 files changed

+14
-20
lines changed

2 files changed

+14
-20
lines changed

Dockerfile

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM ubuntu:22.04
1+
FROM almalinux:9
22

33
SHELL ["/bin/bash", "-c"]
44

@@ -7,37 +7,31 @@ ENV CLASSPATH :/usr/lib/opensourcecobol4j/libcobj.jar:/usr/lib/Open-COBOL-ESQL-4
77
RUN echo 'export CLASSPATH=:/usr/lib/opensourcecobol4j/libcobj.jar:/usr/lib/Open-COBOL-ESQL-4j/postgresql.jar:/usr/lib/Open-COBOL-ESQL-4j/ocesql4j.jar' >> ~/.bashrc
88

99
# install dependencies
10-
RUN apt-get update
11-
RUN apt-get install -y default-jdk build-essential bison flex gettext texinfo autoconf unzip zip gnupg
10+
RUN dnf update -y
11+
RUN dnf install -y gcc make bison flex automake autoconf diffutils gettext java-11-openjdk-devel
12+
1213
# install sbt
13-
RUN echo "deb https://repo.scala-sbt.org/scalasbt/debian all main" | tee /etc/apt/sources.list.d/sbt.list &&\
14-
echo "deb https://repo.scala-sbt.org/scalasbt/debian /" | tee /etc/apt/sources.list.d/sbt_old.list &&\
15-
curl -sL "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x2EE0EA64E40A89B84B2DF73499E82A75642AC823" | apt-key add
16-
RUN apt-get update && apt-get install -y sbt
14+
RUN curl -fL https://github.com/coursier/coursier/releases/latest/download/cs-x86_64-pc-linux.gz | gzip -d > cs && chmod +x cs && echo Y | ./cs setup
1715

1816
# install opensourcecobol4j
1917
RUN cd /root &&\
20-
curl -L -o opensourcecobol4j-v1.1.1.tar.gz https://github.com/opensourcecobol/opensourcecobol4j/archive/refs/tags/v1.1.1.tar.gz &&\
21-
tar zxvf opensourcecobol4j-v1.1.1.tar.gz &&\
22-
cd opensourcecobol4j-1.1.1 &&\
18+
curl -L -o opensourcecobol4j-v1.1.2.tar.gz https://github.com/opensourcecobol/opensourcecobol4j/archive/refs/tags/v1.1.2.tar.gz &&\
19+
tar zxvf opensourcecobol4j-v1.1.2.tar.gz &&\
20+
cd opensourcecobol4j-1.1.2 &&\
2321
./configure --prefix=/usr/ &&\
2422
make &&\
2523
make install &&\
26-
rm ../opensourcecobol4j-v1.1.1.tar.gz
24+
rm ../opensourcecobol4j-v1.1.2.tar.gz
2725

2826
# Install Open COBOL ESQL 4J
27+
ADD Open-COBOL-ESQL-4j /root/Open-COBOL-ESQL-4j
28+
ENV PATH="$PATH:/root/.local/share/coursier/bin"
2929
RUN mkdir -p /usr/lib/Open-COBOL-ESQL-4j &&\
30-
curl -L -o /usr/lib/Open-COBOL-ESQL-4j/postgresql.jar https://jdbc.postgresql.org/download/postgresql-42.2.24.jre6.jar &&\
31-
cd /root &&\
32-
curl -L -o Open-COBOL-ESQL-4j-v1.0.3.tar.gz https://github.com/opensourcecobol/Open-COBOL-ESQL-4j/archive/refs/tags/v1.0.3.tar.gz &&\
33-
tar zxvf Open-COBOL-ESQL-4j-v1.0.3.tar.gz &&\
34-
cd Open-COBOL-ESQL-4j-1.0.3 &&\
35-
cp /usr/lib/Open-COBOL-ESQL-4j/postgresql.jar dblibj/lib &&\
30+
cd /root/Open-COBOL-ESQL-4j &&\
3631
cp /usr/lib/opensourcecobol4j/libcobj.jar dblibj/lib &&\
3732
./configure --prefix=/usr/ &&\
3833
make &&\
39-
make install &&\
40-
rm ../Open-COBOL-ESQL-4j-v1.0.3.tar.gz
34+
make install
4135

4236
# add sample programs
4337
ADD cobol_sample /root/cobol_sample

docker-compose/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ services:
1212
- "5432:5432"
1313

1414
oc4j_client:
15-
image: opensourcecobol/opensourcecobol4j:1.1.1
15+
image: opensourcecobol/opensourcecobol4j:1.1.2
1616
container_name: oc4j_client
1717
stdin_open: true
1818
tty: true

0 commit comments

Comments
 (0)