Giter Site home page Giter Site logo

cloudxtreme / micropurchase Goto Github PK

View Code? Open in Web Editor NEW

This project forked from auth0/micropurchase

0.0 1.0 0.0 1.51 MB

18F's micro-purchase threshold experiment management app.

Home Page: https://18f.gsa.gov/2015/10/13/open-source-micropurchasing/

License: Other

Ruby 77.44% JavaScript 0.09% CSS 3.65% HTML 18.82%

micropurchase's Introduction

Code Climate Test Coverage

Micropurchase

This app will be used to manage bids for 18F's micro-purchase threshold experiment. Vendors will be able to view open issues and bid on them, given they have GitHub accounts and are registered on SAM.gov.

This is a Ruby/Rails application using ActiveRecord and PostgreSQL.

Local Development

The application is running Ruby 2.2.3 and Rails 4.2.4. Libraries are all available via gems.

  • bundle to get your gem dependencies installed
  • Talk to someone of the team to get the authentication secret and key for the github account we are using for authentication. You will want to put these variables in your environment: export GITHUB_KEY=the-magic-key-given-you and export GITHUB_SECRET=another-magic-key.
  • create your test and development databases: bundle exec rake db:create:all db:migrate db:test:prepare
  • start the local server with bundle exec rails s

Testing

bundle exec rspec

or

rake spec

Deployment

This application is deployed on the cloud.gov PaaS which runs on Cloud Foundry. The following instructions are 18F-specific, but could easily be adapted for other Cloud Foundry instances or other web hosts.

Create the app (it's ok if the deploy fails):

$ cf push

Create the database service:

$ cf create-service rds shared-psql micropurchase

Set environment variables with cf set-env:

$ cf set-env micropurchase MPT_3500_GITHUB_KEY [the key]
$ cf set-env micropurchase MPT_3500_GITHUB_SECRET [the secret]

Set up the database:

$ cf-ssh
$~ bundle exec rake db:migrate
$~ bundle exec rake db:seed

Restage the app:

cf restage micropurchase

Manual Deployment

cf push

Automated Deployment

Pull requests merged into the master branch will be automatically deployed to https://micropurchase.18f.gov.

Public domain

This project is in the worldwide public domain. As stated in CONTRIBUTING:

This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.

All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.

micropurchase's People

Contributors

adelevie avatar blacktm avatar esgoodman avatar vdavez avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.