-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
51 lines (39 loc) · 1.98 KB
/
Dockerfile
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
FROM debian:latest AS deb_build_image
RUN apt-get -y update && apt-get -y upgrade && mkdir -p /var/opt/setmy.info/build && \
apt-get -y install cpp gcc g++ make dos2unix gzip bzip2 xz-utils zip
WORKDIR /opt
ADD https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-linux-x86_64.tar.gz /opt
RUN tar xvzf cmake-3.30.2-linux-x86_64.tar.gz && ln -s /opt/cmake-3.30.2-linux-x86_64 /opt/cmake && ls -la
WORKDIR /var/opt/setmy.info/build
COPY ./src/ ./src/
COPY CMakeLists.txt ./
COPY configure ./
COPY changelog ./
RUN dos2unix **/* && dos2unix ./configure && dos2unix ./src/main/sh/build/packages-build.sh && chmod ugoa+x ./src/main/sh/build/packages-build.sh
RUN ./src/main/sh/build/packages-build.sh
RUN ls -la
RUN apt install ./setmy-info-scripts-0.86.0.noarch.deb
RUN ls -la /opt/setmy.info
FROM setmyinfo/setmy-info-rocky:latest AS rpm_build_image
RUN dnf install -y epel-release && \
dnf --enablerepo=epel group && \
dnf config-manager --set-enabled crb && \
dnf config-manager --set-enabled plus && \
dnf config-manager --set-enabled rt && \
dnf update -y && \
mkdir -p /var/opt/setmy.info/build && \
dnf install -y cpp gcc g++ boost-test make dos2unix yum-utils rpmdevtools rpm-build rpm rpmlint
WORKDIR /opt
ADD https://github.com/Kitware/CMake/releases/download/v3.30.2/cmake-3.30.2-linux-x86_64.tar.gz /opt
RUN tar xvzf cmake-3.30.2-linux-x86_64.tar.gz && ln -s /opt/cmake-3.30.2-linux-x86_64 /opt/cmake && ls -la
WORKDIR /var/opt/setmy.info/build
COPY ./src/ ./src/
COPY CMakeLists.txt ./
COPY configure ./
COPY changelog ./
RUN dos2unix **/* && dos2unix ./configure && dos2unix ./src/main/sh/build/packages-build.sh && chmod ugoa+x ./src/main/sh/build/packages-build.sh
COPY --from=deb_build_image /var/opt/setmy.info/build/setmy-info-scripts-0.86.0.noarch.deb /var/opt/setmy.info/build/setmy-info-scripts-0.86.0.noarch.deb
RUN ./src/main/sh/build/packages-build.sh
RUN ls -la
#RUN rpm -i ./setmy-info-scripts-0.86.0.noarch.rpm
#RUN ls -la /opt/setmy.info