GoogleCloudPlatform / GoogleCloudPlatform/ruby-docs-samples

Riccardo trying to fix bugs #1475 and #1477 properly

未关闭
#1,671 3 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
samples
主要语言
Ruby
星标
235
派生
210
PR 合并指标
30 天内没有已合并 PR

描述

# Execution Plan: Resolving PRs 1477 and 1475

## Background
- **PRs:** [1477 (Postgres)](https://github.com/GoogleCloudPlatform/ruby-docs-samples/pull/1477) and [1475 (MySQL)](https://github.com/GoogleCloudPlatform/ruby-docs-samples/pull/1475)
- **Goal:** Update the `app.yaml` files for the GAE Flex Rails 7 tutorials to use modern Ruby versions (e.g., 3.2 or 3.3) on `ubuntu22`, fixing the "end of support" error described in Issue #1476.
- **Current Proposed Fix in PRs:** Added `runtime_config: operating_system: "ubuntu22"` to `app.yaml`.

## Current Roadblocks / Comments
1. **CI Pipeline Failures:** `glasnt` identified that the oldest tested Ruby version is failing due to issues with built-in Gemfile config versions. They suggested updating the repository's oldest supported testing ruby version.
2. **Deployment Errors:** `bipashant` tested the PR and still received an error: `runtime ruby32 is not selectable with operating system ubuntu22`. This suggests the current patch in the PR is incomplete or incorrectly specifies the GAE Flex environment for newer Rubies.

## Recommended Execution Steps

### Step 1: Fix CI Matrix (Address glasnt's feedback)
- Investigate the central CI configurations (likely in `.kokoro/` or `.github/workflows/`).
- Update the Ruby version matrix to drop unsupported EOL Rubies (like 2.6/2.7/3.0) and include modern versions (3.2 and 3.3).
- Update the oldest tested Ruby to at least 3.1 or 3.2.

### Step 2: Validate GAE Flex Configuration (Address bipashant's feedback)
- Research the exact `app.yaml` syntax required to run Ruby 3.2+ on `ubuntu22` in GAE Flex.
- It likely requires either:
1. Adding a `.ruby-version` file to the directories specifying `3.2.3` (or similar) AND keeping the `operating_system: "ubuntu22"` in `app.yaml`.
2. Specifying `runtime_version` under `runtime_config` within `app.yaml`.
- Deploy locally using `gcloud app deploy` (or dry-run) to a test project to ensure the `INVALID_ARGUMENT` error resolves.

### Step 3: Implement Changes in PRs
- For both `appengine/rails-cloudsql-postgres` and `appengine/rails-cloudsql-mysql`:
- Adjust `app.yaml` based on the successful syntax from Step 2.
- Adding `.ruby-version` if necessary.
- Update `Gemfile`/`Gemfile.lock` to reflect changes if bounded by bundler requirements.
- Commit these changes directly to the respective branches for PR 1477 (`palladius-patch-2`) and PR 1475 (`palladius-patch-1`), or create a new consolidated PR linking both.

### Step 4: Finalize
- Confirm CI passes after adjusting the ruby matrix.
- Reply to reviewers `glasnt` and `bipashant`, requesting re-review.
- Merge the PRs.

贡献指南

打开贡献指南

调研方向

从 .kokoro/ 或 .github/workflows/ 配置以及 appengine/rails-cloudsql-postgres 和 appengine/rails-cloudsql-mysql 下的 app.yaml 文件开始。验证所需的 Ruby 和 Ubuntu 22 GAE Flex 语法,然后运行 CI,并使用 gcloud app deploy 或 dry run,确认两个示例的 INVALID_ARGUMENT 错误已解决。

由索引模型根据 Issue 内容生成。

评估

技术栈
google-cloud, rails, ruby
领域
ci-cd, cloud, devops
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。