Skip to content
This repository has been archived by the owner on Nov 5, 2024. It is now read-only.

Commit

Permalink
CD improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
andyone committed May 8, 2024
1 parent aca8f1d commit 5b33aa2
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 37 deletions.
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
target-branch: "develop"
target-branch: "master"
schedule:
interval: "daily"
timezone: "Europe/London"
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ jobs:
'3.0.6',
'3.1.3',
'3.1.4',
'3.1.5',
'3.2.0',
'3.2.1',
'3.2.2',
Expand All @@ -77,7 +76,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Prepare metadata for build
id: metadata
Expand Down Expand Up @@ -195,7 +194,6 @@ jobs:
'3.0.6',
'3.1.3',
'3.1.4',
'3.1.5',
'3.2.0',
'3.2.1',
'3.2.2',
Expand All @@ -220,7 +218,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Prepare metadata for build
id: metadata
Expand Down Expand Up @@ -358,7 +356,7 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Prepare metadata for build
id: metadata
Expand Down
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ This repository contains workflow for the automatic Ruby images building using [
| `3.0.6` | `3.0.6-jemalloc` | `jruby-9.4.1.0` |
| `3.1.3` | `3.1.3-jemalloc` | `jruby-9.4.2.0` |
| `3.1.4` | `3.1.4-jemalloc` | `jruby-9.4.3.0` |
| `3.1.5` | `3.1.5-jemalloc` | `jruby-9.4.4.0` |
| `3.2.0` | `3.2.0-jemalloc` | `jruby-9.4.5.0` |
| `3.2.1` | `3.2.1-jemalloc` | |
| `3.2.0` | `3.2.0-jemalloc` | `jruby-9.4.4.0` |
| `3.2.1` | `3.2.1-jemalloc` | `jruby-9.4.5.0` |
| `3.2.2` | `3.2.2-jemalloc` | |
| `3.2.3` | `3.2.3-jemalloc` | |
| `3.2.4` | `3.2.4-jemalloc` | |
Expand Down
25 changes: 16 additions & 9 deletions jruby.docker
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,31 @@

ARG REGISTRY="docker.io"

## BUILDER #####################################################################
## BASE ########################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as installer

ARG RUBY_VERSION=9.3.9.0
FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as base

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv rbinstall jre11 && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
rbinstall jruby-${RUBY_VERSION} --no-progress
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.*

## INSTALLER ###################################################################

FROM base as installer

ARG RUBY_VERSION=9.3.9.0

RUN rbinstall jruby-${RUBY_VERSION} --no-progress

## FINAL IMAGE ################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8

ARG RUBY_VERSION=9.3.9.0

LABEL org.opencontainers.image.title="rbinstall-ruby" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby" \
LABEL org.opencontainers.image.title="rbinstall-jruby" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby (JRuby-${RUBY_VERSION})" \
org.opencontainers.image.vendor="ESSENTIAL KAOS" \
org.opencontainers.image.authors="Anton Novojilov" \
org.opencontainers.image.licenses="Apache-2.0" \
Expand All @@ -32,7 +38,8 @@ COPY --from=installer /usr/local/rbenv/versions/jruby-${RUBY_VERSION} \

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv jre11 && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
source /etc/profile.d/rbenv.sh && \
rbenv global jruby-${RUBY_VERSION}

Expand Down
27 changes: 17 additions & 10 deletions ruby-jemalloc.docker
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,34 @@

ARG REGISTRY="docker.io"

## BUILDER #####################################################################
## BASE ########################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as installer
FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as base

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv rbinstall libyaml jemalloc && \
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.*

## INSTALLER ###################################################################

FROM base as installer

ARG RUBY_VERSION=3.2.0
ARG WITH_STATIC=no

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv rbinstall libyaml jemalloc && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
rbinstall ${RUBY_VERSION}-jemalloc --no-progress && \
RUN rbinstall ${RUBY_VERSION}-jemalloc --no-progress && \
if [ "${WITH_STATIC}" != "no" ] ; then rm -f /usr/local/rbenv/versions/${RUBY_VERSION}/lib/libruby-static.a ; fi

## FINAL IMAGE ################################################################
## FINAL IMAGE #################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8

ARG RUBY_VERSION=3.2.0
ARG WITH_GCC=no

LABEL org.opencontainers.image.title="rbinstall-ruby" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby" \
LABEL org.opencontainers.image.title="rbinstall-ruby-jemalloc" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby (${RUBY_VERSION}-jemalloc)" \
org.opencontainers.image.vendor="ESSENTIAL KAOS" \
org.opencontainers.image.authors="Anton Novojilov" \
org.opencontainers.image.licenses="Apache-2.0" \
Expand All @@ -36,7 +42,8 @@ COPY --from=installer /usr/local/rbenv/versions/${RUBY_VERSION}-jemalloc \
RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv libyaml jemalloc && \
if [ "${WITH_GCC}" != "no" ] ; then dnf -y -q install gcc ; fi && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
source /etc/profile.d/rbenv.sh && \
rbenv global ${RUBY_VERSION}-jemalloc

Expand Down
25 changes: 16 additions & 9 deletions ruby.docker
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,34 @@

ARG REGISTRY="docker.io"

## BUILDER #####################################################################
## BASE ########################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as installer
FROM ${REGISTRY}/essentialkaos/oraclelinux:8 as base

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv rbinstall libyaml && \
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.*

## INSTALLER ###################################################################

FROM base as installer

ARG RUBY_VERSION=3.2.0
ARG WITH_STATIC=no

RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv rbinstall libyaml && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
rbinstall ${RUBY_VERSION} --no-progress && \
RUN rbinstall ${RUBY_VERSION} --no-progress && \
if [ "${WITH_STATIC}" != "no" ] ; then rm -f /usr/local/rbenv/versions/${RUBY_VERSION}/lib/libruby-static.a ; fi

## FINAL IMAGE ################################################################
## FINAL IMAGE #################################################################

FROM ${REGISTRY}/essentialkaos/oraclelinux:8

ARG RUBY_VERSION=3.2.0
ARG WITH_GCC=no

LABEL org.opencontainers.image.title="rbinstall-ruby" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby" \
org.opencontainers.image.description="RBEnv with prebuilt Ruby (${RUBY_VERSION})" \
org.opencontainers.image.vendor="ESSENTIAL KAOS" \
org.opencontainers.image.authors="Anton Novojilov" \
org.opencontainers.image.licenses="Apache-2.0" \
Expand All @@ -36,7 +42,8 @@ COPY --from=installer /usr/local/rbenv/versions/${RUBY_VERSION} \
RUN dnf -y -q install https://yum.kaos.st/kaos-repo-latest.el8.noarch.rpm && \
dnf -y -q install rbenv libyaml && \
if [ "${WITH_GCC}" != "no" ] ; then dnf -y -q install gcc ; fi && \
dnf -y -q module disable "*" && dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
dnf -y -q module disable "*" && \
dnf clean all && rm -rf /var/cache/dnf /var/log/dnf.* && \
source /etc/profile.d/rbenv.sh && \
rbenv global ${RUBY_VERSION}

Expand Down

0 comments on commit 5b33aa2

Please sign in to comment.