Skip to content
Tool for bulk download of efolder claim files
Branch: master
Clone or download
pkarman Rename API route /veterans -> /document_counts (#1101)
* Rename API route /veterans -> /document_count

* consistent pluralization
Latest commit 91848a8 May 20, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app Rename API route /veterans -> /document_counts (#1101) May 20, 2019
bin Nemo/rails5 (#939) Mar 14, 2018
ci-bin First pass at efolder backend serving sample react app (#824) Jan 17, 2018
client Add feedback page, remove env var for feedback and fix spec test (#1094) May 13, 2019
config Rename API route /veterans -> /document_counts (#1101) May 20, 2019
db Add missing FK index (#1092) May 13, 2019
docs/v2 Re-create documents on each manifest download to ensure we use the la… ( Feb 28, 2018
lib DocumentCounter can use Veteran or Manifest (#1098) May 16, 2019
log Create rails app, and add some additional scaffolding Jan 21, 2016
public Informative error message (#809) Jan 11, 2018
spec Rename API route /veterans -> /document_counts (#1101) May 20, 2019
vendor New styling for Veteran Name and ID (#555) Aug 1, 2017
.gitignore Distribute reads, add indices (#1090) May 7, 2019
.nvmrc First pass at efolder backend serving sample react app (#824) Jan 17, 2018
.rspec Implement fetch document content api endpoint (#503) Jun 28, 2017
.rubocop.yml Fix BGS service (#827) Jan 11, 2018
.ruby-gemset Add ruby-gemset to repo (#248) Oct 13, 2016
.ruby-version Upgrade Ruby, setup docs (#1077) Apr 22, 2019
.scss-lint.yml Update dependencies Aug 5, 2016
.travis.yml Upgrade Ruby, setup docs (#1077) Apr 22, 2019
Gemfile Distribute reads, add indices (#1090) May 7, 2019
Gemfile.lock Distribute reads, add indices (#1090) May 7, 2019
Guardfile Attempting to update rubocop (#822) Jan 10, 2018
Jenkinsfile Update message we send to slack (#913) Mar 1, 2018
Makefile.example Upgrade Ruby, setup docs (#1077) Apr 22, 2019
Procfile
README.md Distribute reads, add indices (#1090) May 7, 2019
Rakefile Attempting to update rubocop (#822) Jan 10, 2018
config.ru Update prometheus url collapser regex to include UUID pattern (#988) Apr 18, 2018
docker-compose.yml fix localstack ports for sqs development (#1085) Apr 30, 2019
newrelic.yml Add NewRelic (#680) Nov 6, 2017
screenshot.png Add screenshot of the app Sep 29, 2016

README.md

Caseflow - eFolder Express

Build Status

About

FOIA Requests that give veterans access to their own VA files take way too long right now. eFolder Express allows VA employees to download all of a veteran's files in a fraction of the time it currently takes. It will also enable attorneys in the appeals process to use best-in-class legal tools to review these documents and so they can provide excellent service to America's veterans.

Start up your docker based environment

We use docker and docker-compose to mock a production environment locally. Prior knowledge of docker is not required, but slowly learning how docker works is encouraged. Please ask a team member for an overview, and/or slowly review the docs linked.

Your development setup of caseflow currently runs Redis, postgres and OracleDB (VACOLS) in Docker.

Setup your postgres user. Run this in your CLI, or better yet, add this to your shell configuration ~/.bashrc

export POSTGRES_HOST=localhost
export POSTGRES_USER=postgres
export POSTGRES_PASSWORD=postgres

Note: If you previously have had redis and postgres installed via brew and would like to switch to docker, do the following:

brew services stop postgresql
brew services stop redis

Start all containers

docker-compose up -d
# run without -d to start your environment and view container logging in the foreground

docker-compose ps
# this shows you the status of all of your dependencies

Turning off dependencies

# this stops all containers
docker-compose down

# this will reset your setup back to scratch. You will need to setup your database schema again if you do this (see below)
docker-compose down -v

First Time Development Setup

You'll need Ruby 2.5.3

$ rbenv install 2.5.3

Install dependencies

$ bundle install $ cd client && yarn && cd -

Create the database

$ rake db:create

Load the schema

$ rake db:schema:load

Run all the app components:

$ foreman

Or run each component separately.

  • the rails server

$ bundle exec rails s -p 3001

  • In a separate terminal, watch for webpack changes

$ cd client && yarn run build --watch

  • And in another separate terminal, start a jobs worker

$ bundle exec shoryuken start -q efolder_development_high_priority efolder_development_low_priority efolder_development_med_priority -R

If you want to convert TIFF files to PDFs then you also need to run the image converter service. You can do this by cloning the appeals-deployment repo, navigating to ansible/utility-roles/imagemagick/files and running docker-compose up. By default if this is not running, TIFFs will gracefully not convert.

If you want to test out the DEMO flow (without VBMS connection),

Visit http://localhost:3001, Type in a file number with "DEMO" in it. (ie: "DEMO123") Watch it download your fake file.

Running Migrations

If a pending migration exists, you will need to run them against both the development and test database:

$ rake db:migrate

$ RAILS_ENV=test rake db:migrate

Running Tests

In order to run tests, you will first need to globally install phantomJS

$ (sudo) npm install -g phantomjs

The CI environment uses standard ports for services like PostgreSQL and Redis but local tests require a different port. Add this to a .env file in your application root directory:

POSTGRES_PORT=15432
REDIS_URL_CACHE=redis://localhost:16379/0/cache/
REDIS_URL_SIDEKIQ=redis://localhost:16379

Then to run the test suite:

$ rake

Monitoring

We use NewRelic to monitor the app. By default, it's disabled locally. To enable it, do:

NEW_RELIC_LICENSE_KEY='<key as displayed on NewRelic.com>' NEW_RELIC_AGENT_ENABLED=true bundle exec rails s

You may wish to do this if you are debugging our NewRelic integration, for instance.

Run connected to UAT

First, you'll need a VA machine. Next, you'll need the secrets file. These come from the appeals deployment repo. Run decrypt.sh and source the appropriate secrets environment.

Then you must setup the staging DB. Run:

$ RAILS_ENV=staging rake db:create $ RAILS_ENV=staging rake db:schema:load

Finally, you can run the server and shoryuken. In one tab you can run:

$ rails s -e staging

In a separate tab run:

$ RAILS_ENV=staging bundle exec shoryuken start -q efolder_staging_high_priority efolder_staging_low_priority efolder_staging_med_priority -R

Now when you go to localhost:3001 you'll be prompted with a fake login screen. Use any of these logins to impersonate a UAT user.

You can’t perform that action at this time.