Skip to content

Inform unverified users trying to authorise with oauth #668

Inform unverified users trying to authorise with oauth

Inform unverified users trying to authorise with oauth #668

Workflow file for this run

name: Ruby
on: [push, pull_request]
jobs:
build:
name: The Build
runs-on: ubuntu-20.04
services:
redis:
image: redis:4
ports:
- 6379:6379
postgres:
image: postgres:10
env:
POSTGRES_DB: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
ports:
- 5432:5432
# needed because the postgres container does not provide a healthcheck
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- uses: actions/checkout@v2
- name: Show available Ruby versions
run: |
ls $RUNNER_TOOL_CACHE/Ruby
uname -a
cat /etc/os-release
- name: Set up Ruby
uses: ruby/setup-ruby@v1
#with:
#bundler-cache: true
- name: Cache gems
uses: actions/cache@v1
with:
path: vendor/bundle
key: ${{ runner.os }}-gem-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gem-
- name: Install required packages
run: |
sudo apt-get update -y
sudo apt-get install libpq-dev
sudo apt-get install g++ qt5-default libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools gstreamer1.0-x
- name: Bundle
run: |
pwd
gem install bundler
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
- name: Test
run: |
RAILS_ENV=test bundle exec rails db:create
RAILS_ENV=test bundle exec rails db:schema:load
npm i
bundle exec rake
env:
#Note: DATABASE_URL does not work in TEST env.
TEST_DB_HOST: localhost
TEST_DB_NAME: postgres
TEST_DB_PASSWORD: postgres
TEST_DB_USERNAME: postgres
PG_PORT: ${{ job.services.postgres.ports['5432'] }}
FABLAB_URL: http://www.fablabs.local
- name: Deploy to server via SSH
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.HOST }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
username: ${{ secrets.USERNAME }}
script: |
pwd
cd fablabs.io
pwd
./scripts/deploy.sh
if: false # We do not have a staging server at the moment
#if: github.ref == 'refs/heads/master' && job.status == 'success'