我正在使用 Ruby on Rails 应用程序尝试 GitHub Actions for CI。
我的设置是使用 VM,而不是在容器中运行 Ruby 构建。
这是我的工作流程 yml。它一直运行而没有错误,直到步骤“设置数据库”。
name: Rails CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:10.10
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: db_test
ports:
- 5432/tcp
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
redis:
image: redis:latest
ports:
- 6379/tcp
steps:
- uses: actions/checkout@v1
- name: Set up ruby 2.5
uses: actions/setup-ruby@v1
with:
ruby-version: 2.5.5
- name: Set up node …Run Code Online (Sandbox Code Playgroud)