Skip to content
View Carson004's full-sized avatar

Block or report Carson004

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Please don't include any personal information such as legal names or email addresses. Maximum 100 characters, markdown supported. This note will be visible to only you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
Carson004/README.md

oanda-api-rails

CI Maintainability codecov GitHub license JavaScript Style Guide Ruby Style Guide

Get exchange data using OANDA API

Prerequisites

  • Ruby 2.7+
  • Node.js 12.22.0+ || 14.17.0+ || 16.0.0+
  • Yarn 1.x+

Installation

Set up Rails app

First, install the gems and javascript packages required by the application:

bundle
yarn

Next, execute the database migrations/schema setup:

bin/rails db:setup

Resque settings

Create a configuration file to manage Resque and resque-scheduler with God

RAILS_ENV=[RAILS_ENV] bundle exec itamae local config/itamae/resque.rb

Load configuration file

god -c /etc/god/master.conf

Resque, resque-scheduler operation with God

  • check the status
  • start
  • restart
  • stop
god status resque-oanda_api_rails
god start resque-oanda_api_rails
god restart resque-oanda_api_rails
god stop resque-oanda_api_rails

Start the app

development

bin/rails start

production

bin/rails assets:precompile RAILS_ENV=production
bin/rails s -e production

Configuration Files

Notify when Resque job failed

If a Resque job fails, a notification email will be sent.
Please fill in the settings of email to config/mail.yml .
The following is an example when sending from Gmail:

production:
  delivery_method: 'smtp'
  smtp_settings:
    address: 'smtp.gmail.com'
    port: 587
    domain: 'gmail.com'
    user_name: [USER_NAME]
    password: [PASSWORD]
    authentication: 'plain'
    enable_starttls_auto: true
  recipients:
    - [EMAIL_ADDRESS]

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

Popular repositories Loading

  1. Carson004 Carson004 Public

    Config files for my GitHub profile.

    Ruby 1

  2. oanda-api-rails oanda-api-rails Public

    Forked from mishina2228/oanda-api-rails

    Get exchange data using OANDA API

    Ruby 1

  3. Blockchair.Support Blockchair.Support Public

    Forked from Blockchair/Blockchair.Support

    Public repository for issues and feature requests. Submit your favorite bug!

    1

  4. assets assets Public

    Forked from trustwallet/assets

    A comprehensive, up-to-date collection of information about several thousands (!) of crypto tokens.

    Go