Skip to content

Commit 5fdbff4

Browse files
committed
Add Ruby 3.3
1 parent d120546 commit 5fdbff4

31 files changed

+824
-0
lines changed

Diff for: 3.3/Dockerfile.c8s

+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
FROM quay.io/sclorg/s2i-base-c8s:c8s
2+
3+
# This image provides a Ruby environment you can use to run your Ruby
4+
# applications.
5+
6+
EXPOSE 8080
7+
8+
ENV RUBY_MAJOR_VERSION=3 \
9+
RUBY_MINOR_VERSION=3
10+
11+
ENV RUBY_VERSION="${RUBY_MAJOR_VERSION}.${RUBY_MINOR_VERSION}" \
12+
RUBY_SCL_NAME_VERSION="${RUBY_MAJOR_VERSION}${RUBY_MINOR_VERSION}"
13+
14+
ENV RUBY_SCL="ruby-${RUBY_SCL_NAME_VERSION}" \
15+
IMAGE_NAME="ubi8/ruby-${RUBY_SCL_NAME_VERSION}" \
16+
SUMMARY="Platform for building and running Ruby $RUBY_VERSION applications" \
17+
DESCRIPTION="Ruby $RUBY_VERSION available as container is a base platform for \
18+
building and running various Ruby $RUBY_VERSION applications and frameworks. \
19+
Ruby is the interpreted scripting language for quick and easy object-oriented programming. \
20+
It has many features to process text files and to do system management tasks (as in Perl). \
21+
It is simple, straight-forward, and extensible."
22+
23+
LABEL summary="$SUMMARY" \
24+
description="$DESCRIPTION" \
25+
io.k8s.description="$DESCRIPTION" \
26+
io.k8s.display-name="Ruby ${RUBY_VERSION}" \
27+
io.openshift.expose-services="8080:http" \
28+
io.openshift.tags="builder,ruby,ruby${RUBY_SCL_NAME_VERSION},${RUBY_SCL}" \
29+
com.redhat.component="${RUBY_SCL}-container" \
30+
name="${IMAGE_NAME}" \
31+
version="1" \
32+
com.redhat.license_terms="https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI" \
33+
usage="s2i build https://github.com/sclorg/s2i-ruby-container.git \
34+
--context-dir=${RUBY_VERSION}/test/puma-test-app/ ${IMAGE_NAME} ruby-sample-app" \
35+
maintainer="SoftwareCollections.org <[email protected]>"
36+
37+
RUN yum -y module enable ruby:$RUBY_VERSION && \
38+
INSTALL_PKGS=" \
39+
libffi-devel \
40+
ruby \
41+
ruby-devel \
42+
rubygem-rake \
43+
rubygem-bundler \
44+
ruby-bundled-gems \
45+
redhat-rpm-config \
46+
" && \
47+
yum install -y --setopt=tsflags=nodocs ${INSTALL_PKGS} && \
48+
yum reinstall -y --setopt=tsflags=nodocs tzdata && \
49+
yum -y clean all --enablerepo='*' && \
50+
ruby -v | grep -qe "^ruby $RUBY_VERSION\." && echo "Found VERSION $RUBY_VERSION" && \
51+
rpm -V ${INSTALL_PKGS}
52+
53+
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH
54+
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
55+
56+
# Copy extra files to the image.
57+
COPY ./root/ /
58+
59+
# Drop the root user and make the content of /opt/app-root owned by user 1001
60+
RUN chown -R 1001:0 ${APP_ROOT} && chmod -R ug+rwx ${APP_ROOT} && \
61+
rpm-file-permissions
62+
63+
USER 1001
64+
65+
# Set the default CMD to print the usage of the language image
66+
CMD $STI_SCRIPTS_PATH/usage

Diff for: 3.3/Dockerfile.c9s

+66
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
FROM quay.io/sclorg/s2i-base-c9s:c9s
2+
3+
# This image provides a Ruby environment you can use to run your Ruby
4+
# applications.
5+
6+
EXPOSE 8080
7+
8+
ENV RUBY_MAJOR_VERSION=3 \
9+
RUBY_MINOR_VERSION=3
10+
11+
ENV RUBY_VERSION="${RUBY_MAJOR_VERSION}.${RUBY_MINOR_VERSION}" \
12+
RUBY_SCL_NAME_VERSION="${RUBY_MAJOR_VERSION}${RUBY_MINOR_VERSION}"
13+
14+
ENV RUBY_SCL="ruby-${RUBY_SCL_NAME_VERSION}" \
15+
IMAGE_NAME="ubi8/ruby-${RUBY_SCL_NAME_VERSION}" \
16+
SUMMARY="Platform for building and running Ruby $RUBY_VERSION applications" \
17+
DESCRIPTION="Ruby $RUBY_VERSION available as container is a base platform for \
18+
building and running various Ruby $RUBY_VERSION applications and frameworks. \
19+
Ruby is the interpreted scripting language for quick and easy object-oriented programming. \
20+
It has many features to process text files and to do system management tasks (as in Perl). \
21+
It is simple, straight-forward, and extensible."
22+
23+
LABEL summary="$SUMMARY" \
24+
description="$DESCRIPTION" \
25+
io.k8s.description="$DESCRIPTION" \
26+
io.k8s.display-name="Ruby ${RUBY_VERSION}" \
27+
io.openshift.expose-services="8080:http" \
28+
io.openshift.tags="builder,ruby,ruby${RUBY_SCL_NAME_VERSION},${RUBY_SCL}" \
29+
com.redhat.component="${RUBY_SCL}-container" \
30+
name="${IMAGE_NAME}" \
31+
version="1" \
32+
com.redhat.license_terms="https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI" \
33+
usage="s2i build https://github.com/sclorg/s2i-ruby-container.git \
34+
--context-dir=${RUBY_VERSION}/test/puma-test-app/ ${IMAGE_NAME} ruby-sample-app" \
35+
maintainer="SoftwareCollections.org <[email protected]>"
36+
37+
RUN yum -y module enable ruby:$RUBY_VERSION && \
38+
INSTALL_PKGS=" \
39+
libffi-devel \
40+
ruby \
41+
ruby-devel \
42+
rubygem-rake \
43+
rubygem-bundler \
44+
ruby-bundled-gems \
45+
redhat-rpm-config \
46+
" && \
47+
yum install -y --setopt=tsflags=nodocs ${INSTALL_PKGS} && \
48+
yum reinstall -y --setopt=tsflags=nodocs tzdata && \
49+
yum -y clean all --enablerepo='*' && \
50+
ruby -v | grep -qe "^ruby $RUBY_VERSION\." && echo "Found VERSION $RUBY_VERSION" && \
51+
rpm -V ${INSTALL_PKGS}
52+
53+
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH
54+
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
55+
56+
# Copy extra files to the image.
57+
COPY ./root/ /
58+
59+
# Drop the root user and make the content of /opt/app-root owned by user 1001
60+
RUN chown -R 1001:0 ${APP_ROOT} && chmod -R ug+rwx ${APP_ROOT} && \
61+
rpm-file-permissions
62+
63+
USER 1001
64+
65+
# Set the default CMD to print the usage of the language image
66+
CMD $STI_SCRIPTS_PATH/usage

Diff for: 3.3/Dockerfile.fedora

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
FROM quay.io/fedora/s2i-base:39
2+
3+
# This image provides a Ruby environment you can use to run your Ruby
4+
# applications.
5+
6+
EXPOSE 8080
7+
8+
ENV NAME=ruby \
9+
RUBY_VERSION=3.3 \
10+
RUBY_SHORT_VER=33 \
11+
VERSION=0
12+
13+
ENV SUMMARY="Platform for building and running Ruby $RUBY_VERSION applications" \
14+
DESCRIPTION="Ruby $RUBY_VERSION available as container is a base platform for \
15+
building and running various Ruby $RUBY_VERSION applications and frameworks. \
16+
Ruby is the interpreted scripting language for quick and easy object-oriented programming. \
17+
It has many features to process text files and to do system management tasks (as in Perl). \
18+
It is simple, straight-forward, and extensible."
19+
20+
LABEL summary="$SUMMARY" \
21+
description="$DESCRIPTION" \
22+
io.k8s.description="$DESCRIPTION" \
23+
io.k8s.display-name="Ruby ${RUBY_VERSION}" \
24+
io.openshift.expose-services="8080:http" \
25+
io.openshift.tags="builder,ruby,ruby${RUBY_SHORT_VER}" \
26+
com.redhat.component="$NAME" \
27+
name="fedora/$NAME-$RUBY_SHORT_VER" \
28+
version="$VERSION" \
29+
usage="s2i build https://github.com/sclorg/s2i-ruby-container.git --context-dir=${RUBY_VERSION}/test/puma-test-app/ quay.io/fedora/$NAME-$RUBY_SHORT_VER ruby-sample-app" \
30+
maintainer="SoftwareCollections.org <[email protected]>"
31+
32+
# Install required packages
33+
RUN INSTALL_PKGS="ruby ruby-devel rubygem-bundler ruby-bundled-gems rubygem-rake rubygems-devel redhat-rpm-config libffi-devel" && \
34+
dnf install -y --setopt=tsflags=nodocs $INSTALL_PKGS && \
35+
rpm -V $INSTALL_PKGS && \
36+
ruby -v | grep -qe "^ruby $RUBY_VERSION\." && echo "Found VERSION $RUBY_VERSION" && \
37+
dnf clean all
38+
39+
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH
40+
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
41+
42+
# Copy extra files to the image.
43+
COPY ./root/ /
44+
45+
# Drop the root user and make the content of /opt/app-root owned by user 1001
46+
RUN chown -R 1001:0 ${APP_ROOT} && chmod -R ug+rwx ${APP_ROOT} && \
47+
rpm-file-permissions
48+
49+
USER 1001
50+
51+
# Set the default CMD to print the usage of the language image
52+
CMD $STI_SCRIPTS_PATH/usage

Diff for: 3.3/Dockerfile.rhel8

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
FROM ubi8/s2i-base
2+
3+
# This image provides a Ruby environment you can use to run your Ruby
4+
# applications.
5+
6+
EXPOSE 8080
7+
8+
ENV RUBY_MAJOR_VERSION=3 \
9+
RUBY_MINOR_VERSION=3
10+
11+
ENV RUBY_VERSION="${RUBY_MAJOR_VERSION}.${RUBY_MINOR_VERSION}" \
12+
RUBY_SCL_NAME_VERSION="${RUBY_MAJOR_VERSION}${RUBY_MINOR_VERSION}"
13+
14+
ENV RUBY_SCL="ruby-${RUBY_SCL_NAME_VERSION}" \
15+
IMAGE_NAME="ubi8/ruby-${RUBY_SCL_NAME_VERSION}" \
16+
SUMMARY="Platform for building and running Ruby $RUBY_VERSION applications" \
17+
DESCRIPTION="Ruby $RUBY_VERSION available as container is a base platform for \
18+
building and running various Ruby $RUBY_VERSION applications and frameworks. \
19+
Ruby is the interpreted scripting language for quick and easy object-oriented programming. \
20+
It has many features to process text files and to do system management tasks (as in Perl). \
21+
It is simple, straight-forward, and extensible."
22+
23+
LABEL summary="$SUMMARY" \
24+
description="$DESCRIPTION" \
25+
io.k8s.description="$DESCRIPTION" \
26+
io.k8s.display-name="Ruby ${RUBY_VERSION}" \
27+
io.openshift.expose-services="8080:http" \
28+
io.openshift.tags="builder,ruby,ruby${RUBY_SCL_NAME_VERSION},${RUBY_SCL}" \
29+
com.redhat.component="${RUBY_SCL}-container" \
30+
name="${IMAGE_NAME}" \
31+
version="1" \
32+
com.redhat.license_terms="https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI" \
33+
usage="s2i build https://github.com/sclorg/s2i-ruby-container.git \
34+
--context-dir=${RUBY_VERSION}/test/puma-test-app/ ${IMAGE_NAME} ruby-sample-app" \
35+
maintainer="SoftwareCollections.org <[email protected]>"
36+
37+
RUN yum -y module enable ruby:$RUBY_VERSION && \
38+
INSTALL_PKGS=" \
39+
libffi-devel \
40+
ruby \
41+
ruby-devel \
42+
rubygem-rake \
43+
rubygem-bundler \
44+
ruby-bundled-gems \
45+
redhat-rpm-config \
46+
" && \
47+
yum install -y --setopt=tsflags=nodocs ${INSTALL_PKGS} && \
48+
yum -y clean all --enablerepo='*' && \
49+
ruby -v | grep -qe "^ruby $RUBY_VERSION\." && echo "Found VERSION $RUBY_VERSION" && \
50+
rpm -V ${INSTALL_PKGS}
51+
52+
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH
53+
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
54+
55+
# Copy extra files to the image.
56+
COPY ./root/ /
57+
58+
# Drop the root user and make the content of /opt/app-root owned by user 1001
59+
RUN chown -R 1001:0 ${APP_ROOT} && chmod -R ug+rwx ${APP_ROOT} && \
60+
rpm-file-permissions
61+
62+
USER 1001
63+
64+
# Set the default CMD to print the usage of the language image
65+
CMD $STI_SCRIPTS_PATH/usage

Diff for: 3.3/Dockerfile.rhel9

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
FROM ubi9/s2i-base
2+
3+
# This image provides a Ruby environment you can use to run your Ruby
4+
# applications.
5+
6+
EXPOSE 8080
7+
8+
ENV RUBY_MAJOR_VERSION=3 \
9+
RUBY_MINOR_VERSION=3
10+
11+
ENV RUBY_VERSION="${RUBY_MAJOR_VERSION}.${RUBY_MINOR_VERSION}" \
12+
RUBY_SCL_NAME_VERSION="${RUBY_MAJOR_VERSION}${RUBY_MINOR_VERSION}"
13+
14+
ENV RUBY_SCL="ruby-${RUBY_SCL_NAME_VERSION}" \
15+
IMAGE_NAME="ubi9/ruby-${RUBY_SCL_NAME_VERSION}" \
16+
SUMMARY="Platform for building and running Ruby $RUBY_VERSION applications" \
17+
DESCRIPTION="Ruby $RUBY_VERSION available as container is a base platform for \
18+
building and running various Ruby $RUBY_VERSION applications and frameworks. \
19+
Ruby is the interpreted scripting language for quick and easy object-oriented programming. \
20+
It has many features to process text files and to do system management tasks (as in Perl). \
21+
It is simple, straight-forward, and extensible."
22+
23+
LABEL summary="$SUMMARY" \
24+
description="$DESCRIPTION" \
25+
io.k8s.description="$DESCRIPTION" \
26+
io.k8s.display-name="Ruby ${RUBY_VERSION}" \
27+
io.openshift.expose-services="8080:http" \
28+
io.openshift.tags="builder,ruby,ruby${RUBY_SCL_NAME_VERSION},${RUBY_SCL}" \
29+
com.redhat.component="${RUBY_SCL}-container" \
30+
name="${IMAGE_NAME}" \
31+
version="1" \
32+
com.redhat.license_terms="https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI" \
33+
usage="s2i build https://github.com/sclorg/s2i-ruby-container.git \
34+
--context-dir=${RUBY_VERSION}/test/puma-test-app/ ${IMAGE_NAME} ruby-sample-app" \
35+
maintainer="SoftwareCollections.org <[email protected]>"
36+
37+
RUN yum -y module enable ruby:$RUBY_VERSION && \
38+
INSTALL_PKGS=" \
39+
libffi-devel \
40+
ruby \
41+
ruby-devel \
42+
rubygem-rake \
43+
rubygem-bundler \
44+
ruby-bundled-gems \
45+
redhat-rpm-config \
46+
" && \
47+
yum install -y --setopt=tsflags=nodocs ${INSTALL_PKGS} && \
48+
yum -y clean all --enablerepo='*' && \
49+
ruby -v | grep -qe "^ruby $RUBY_VERSION\." && echo "Found VERSION $RUBY_VERSION" && \
50+
rpm -V ${INSTALL_PKGS}
51+
52+
# Copy the S2I scripts from the specific language image to $STI_SCRIPTS_PATH
53+
COPY ./s2i/bin/ $STI_SCRIPTS_PATH
54+
55+
# Copy extra files to the image.
56+
COPY ./root/ /
57+
58+
# Drop the root user and make the content of /opt/app-root owned by user 1001
59+
RUN chown -R 1001:0 ${APP_ROOT} && chmod -R ug+rwx ${APP_ROOT} && \
60+
rpm-file-permissions
61+
62+
USER 1001
63+
64+
# Set the default CMD to print the usage of the language image
65+
CMD $STI_SCRIPTS_PATH/usage

0 commit comments

Comments
 (0)