From f4f5758588849e2cd2a6c3a6b1cb2a1406ff5d80 Mon Sep 17 00:00:00 2001 From: ydaniju Date: Thu, 1 Aug 2024 01:39:01 +0200 Subject: [PATCH] fix workflow --- .github/workflows/ruby.yml | 5 +++++ .gitignore | 3 ++- config/database.yml | 4 +--- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index c4bc234..f2d2134 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -16,6 +16,11 @@ on: permissions: contents: read +env: + DATABASE_URL: postgres://postgres:@localhost:5432/test + POSTGRES_PASSWORD: postgres + POSTGRES_USER: postgres + jobs: test: runs-on: ubuntu-latest diff --git a/.gitignore b/.gitignore index 14e0ff5..f5f6e32 100644 --- a/.gitignore +++ b/.gitignore @@ -21,4 +21,5 @@ # Ignore specs coverage /coverage/.resultset.json -/coverage/.last_run.json \ No newline at end of file +/coverage/.last_run.json +/spec/reports diff --git a/config/database.yml b/config/database.yml index 3a63694..f000ea6 100644 --- a/config/database.yml +++ b/config/database.yml @@ -19,9 +19,7 @@ development: # Do not set this db to the same as development or production. test: <<: *default - url: <%= ENV['DATABASE_URL'] || "postgres://postgres:@localhost:5432/test" %> - username: postgres - password: postgres + url: <%= ENV['DATABASE_URL'] || "postgres://#{ENV['USER']}:@localhost:5432/test" %> production: <<: *default