Skip to content

Commit

Permalink
Use Ruby version from .ruby-version.
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeMcQuaid committed May 23, 2024
1 parent 7a75a2b commit 8c52668
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ jobs:
- name: Set up Ruby
uses: ruby/setup-ruby@cacc9f1c0b3f4eb8a16a6bb0ed10897b43b9de49 # v1.176.0
with:
ruby-version: "3.3"
bundler-cache: true

- name: Run RuboCop
Expand Down Expand Up @@ -62,7 +61,7 @@ jobs:
- name: Build Docker image
run: |-
docker build --tag "$IMAGE" .
docker build --tag "$IMAGE" --build-arg RUBY_VERSION=$(cat .ruby-version)
- name: Publish Docker image
run: |-
Expand Down
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ruby:3.3-alpine
ARG RUBY_VERSION
FROM ruby:$RUBY_VERSION-alpine

# Currently need git as some dependencies are defined with git repos at the moment
RUN apk add --no-cache --virtual .build-deps git build-base
Expand Down
2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

source "https://rubygems.org"

ruby file: ".ruby-version"

gem "faraday-retry" # for octokit
gem "jwt"
gem "octokit"
Expand Down

0 comments on commit 8c52668

Please sign in to comment.