Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkCaronJr authored Jul 31, 2024
1 parent d343c5b commit 5f4bf26
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@ FROM redhat/ubi8:latest

# Clean up and update yum, then install required packages
RUN yum clean all && yum -y update -v && yum -y upgrade -v && \
yum -y install wget rpm-build rpm-devel rpmlint make coreutils diffutils patch rpmdevtools make python -v
yum -y install wget rpm-build rpmlint make coreutils diffutils patch python3 -v

# Set up the build directories
RUN mkdir -p /root/rpmbuild/{RPMS/noarch,SOURCES,SPECS,SRPMS}
# Create the rpm build directories
RUN mkdir -p /root/rpmbuild/RPMS/noarch && \
mkdir -p /root/rpmbuild/SOURCES && \
mkdir -p /root/rpmbuild/SPECS && \
mkdir -p /root/rpmbuild/SRPMS

# Copy source and spec files
# Copy source files and spec file
COPY *.tar.gz /root/rpmbuild/SOURCES/
COPY *.patch /root/rpmbuild/SOURCES/
ADD tomcat.spec /root/rpmbuild/SPECS/

# Define the volume for the built RPMs
VOLUME /root/rpmbuild/RPMS/noarch

# Set the working directory
# Set working directory
WORKDIR /root/rpmbuild/RPMS/noarch

# Default command to build the RPM
CMD ["rpmbuild", "--target", "noarch", "-v", "-bb", "/root/rpmbuild/SPECS/tomcat.spec"]
# Command to build RPM
CMD ["rpmbuild", "--target", "noarch", "-v", "-bb", "tomcat.spec"]

0 comments on commit 5f4bf26

Please sign in to comment.