hackforla / ops

A repository for the OPS Community of Practice
https://github.com/orgs/hackforla/projects/73
MIT License
8 stars 7 forks source link

GHPAGES-DOCKER needs to be updated - ruby gem #142

Open danielridgebot opened 4 weeks ago

danielridgebot commented 4 weeks ago

GitHub Pages is now using v3.3.4 of Ruby. You are using v2.7. Please refer to the ghpages-docker Wiki for instructions on how to update.

danielridgebot commented 3 weeks ago
roslynwythe commented 3 weeks ago

@fyliu I updated the Dockerfile in my fork and created a PR https://github.com/hackforla/ghpages-docker/pull/3 but please advise how/when will we test?

fyliu commented 3 weeks ago

@roslynwythe

I was going to run the website code with the old and then the new image to see that they both work. Are there specific things that's good to check on?

It turns out I can't build the old image from main because I'm guessing the code doesn't pin specific versions of ruby packages, causing ruby complains about rubygems-update requiring ruby >= 3.0.0, which it doesn't have.

So I only built the updated PR branch.

# build the image with the existing <repo>/<name> but with a testing tag
docker build -t hackforlaops/ghpages:testing .

Then went into the image to check the gem versions

docker run -it hackforlaops/ghpages:testing sh

# inside the container
# check ruby version
ruby --version

# output
ruby 3.3.4 ...

# check gem version
gem list | grep github-pages

# output
github-pages (232)
...

So that looks good.

fyliu commented 3 weeks ago

@roslynwythe I think I should approve the PR if the website looks okay and you can do further testing and merge it when you feel it's ready.

Maybe find some website team members to try it? Or would it be better to push a hackforlaops/ghpages:testing image to the public and ask people to test that before merging? The website repo docker-compose file points to hackforlaops/ghpages:latest.

fyliu commented 3 weeks ago

@roslynwythe I think your message disappeared, but it looked right. It's probably its own separate issue though.

Since it's a separate workflow file, it's probably okay to tack on an automation to push a test image when a PR is approved. Something like...

on:
  workflow_dispatch:
  pull_request_review:
    types: [submitted]
jobs:
  build:
    if: github.event.pull_request_review == 'submitted' && github.event.review.state == 'approved'
    runs-on: ubuntu-latest
    steps: ...
roslynwythe commented 2 weeks ago