Skip to content

Commit

Permalink
Upgrade cicd for cuegui and cuesubmit to rocky9
Browse files Browse the repository at this point in the history
  • Loading branch information
DiegoTavares committed Dec 13, 2024
1 parent 4822b5f commit 2b00f5c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 42 deletions.
34 changes: 10 additions & 24 deletions cuegui/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
FROM --platform=linux/x86_64 centos:7
FROM --platform=linux/x86_64 rockylinux:9.3

WORKDIR /src

# centos:7 repos moved to vault.centos
RUN sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/CentOS-*.repo
RUN sed -i s/^#.*baseurl=http/baseurl=http/g /etc/yum.repos.d/CentOS-*.repo
RUN sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/CentOS-*.repo

RUN yum -y install \
epel-release \
fontconfig \
Expand All @@ -25,20 +20,13 @@ RUN yum -y install \
xcb-util-wm.x86_64

RUN yum -y install \
python36 \
python36-devel \
python36-pip

RUN python3.6 -m pip install --upgrade pip
RUN python3.6 -m pip install --upgrade setuptools

RUN dbus-uuidgen > /etc/machine-id
python\
python-pip

COPY LICENSE ./
COPY requirements.txt ./
COPY requirements_gui.txt ./
RUN python -m pip install --upgrade pip

RUN python3.6 -m pip install -r requirements.txt -r requirements_gui.txt
COPY LICENSE requirements.txt requirements_gui.txt ./
RUN python -m pip install -r requirements.txt -r requirements_gui.txt

COPY proto/ ./proto
COPY pycue/README.md ./pycue/
Expand All @@ -47,15 +35,15 @@ COPY pycue/FileSequence ./pycue/FileSequence
COPY pycue/opencue ./pycue/opencue
COPY ci/fix_compiled_proto.py .

RUN python3.6 -m grpc_tools.protoc \
RUN python -m grpc_tools.protoc \
-I=./proto \
--python_out=./pycue/opencue/compiled_proto \
--grpc_python_out=./pycue/opencue/compiled_proto \
./proto/*.proto

# Fix imports to work in both Python 2 and 3. See
# <https://github.com/protocolbuffers/protobuf/issues/1491> for more info.
RUN python3 ./fix_compiled_proto.py pycue/opencue/compiled_proto
RUN python ./fix_compiled_proto.py pycue/opencue/compiled_proto

COPY cuegui/README.md ./cuegui/
COPY cuegui/setup.py ./cuegui/
Expand All @@ -65,10 +53,8 @@ COPY cuegui/cuegui ./cuegui/cuegui
COPY VERSION.in VERSIO[N] ./
RUN test -e VERSION || echo "$(cat VERSION.in)" | tee VERSION

RUN cd pycue && python3.6 setup.py install

RUN cd cuegui && xvfb-run -d python3.6 setup.py test

RUN cd pycue && python setup.py install
RUN cd cuegui && xvfb-run -d python setup.py test
RUN cp LICENSE requirements.txt requirements_gui.txt VERSION cuegui/

RUN versioned_name="cuegui-$(cat ./VERSION)-all" \
Expand Down
27 changes: 10 additions & 17 deletions cuesubmit/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,31 +1,24 @@
FROM --platform=linux/x86_64 centos:7
FROM --platform=linux/x86_64 rockylinux:9.3

WORKDIR /src

# centos:7 repos moved to vault.centos
RUN sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/CentOS-*.repo
RUN sed -i s/^#.*baseurl=http/baseurl=http/g /etc/yum.repos.d/CentOS-*.repo
RUN sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/CentOS-*.repo

RUN yum -y install \
epel-release \
gcc \
mesa-libGL \
python-devel

RUN yum -y install \
python36 \
python36-devel \
python36-pip
python \
python-pip

RUN python3.6 -m pip install --upgrade pip
RUN python3.6 -m pip install --upgrade setuptools
RUN python -m pip install --upgrade pip

COPY LICENSE ./
COPY requirements.txt ./
COPY requirements_gui.txt ./

RUN python3.6 -m pip install -r requirements.txt -r requirements_gui.txt
RUN python -m pip install -r requirements.txt -r requirements_gui.txt

COPY proto/ ./proto
COPY pycue/README.md ./pycue/
Expand All @@ -34,15 +27,15 @@ COPY pycue/opencue ./pycue/opencue
COPY pycue/FileSequence ./pycue/FileSequence
COPY ci/fix_compiled_proto.py .

RUN python3.6 -m grpc_tools.protoc \
RUN python -m grpc_tools.protoc \
-I=./proto \
--python_out=./pycue/opencue/compiled_proto \
--grpc_python_out=./pycue/opencue/compiled_proto \
./proto/*.proto

# Fix imports to work in both Python 2 and 3. See
# <https://github.com/protocolbuffers/protobuf/issues/1491> for more info.
RUN python3 ./fix_compiled_proto.py pycue/opencue/compiled_proto
RUN python ./fix_compiled_proto.py pycue/opencue/compiled_proto

COPY pyoutline/README.md ./pyoutline/
COPY pyoutline/setup.py ./pyoutline/
Expand All @@ -59,9 +52,9 @@ COPY cuesubmit/cuesubmit ./cuesubmit/cuesubmit
COPY VERSION.in VERSIO[N] ./
RUN test -e VERSION || echo "$(cat VERSION.in)" | tee VERSION

RUN cd pycue && python3.6 setup.py install
RUN cd pyoutline && python3.6 setup.py install
RUN cd cuesubmit && python3.6 setup.py test
RUN cd pycue && python setup.py install
RUN cd pyoutline && python setup.py install
RUN cd cuesubmit && python setup.py test

RUN cp LICENSE requirements.txt requirements_gui.txt VERSION cuesubmit/

Expand Down
2 changes: 1 addition & 1 deletion requirements_gui.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ PySide6==6.5.3;python_version=="3.11"
PySide2==5.15.2.1;python_version<="3.10"
QtPy==1.11.3;python_version<"3.7"
QtPy==2.4.1;python_version>="3.7"
NodeGraphQtPy==0.6.38.6;python_version>="3.7"
NodeGraphQtPy==0.6.38.6

0 comments on commit 2b00f5c

Please sign in to comment.