Awesome Open Source
Awesome Open Source

Cloud Insurance Co. - Main web site and chat bot

master Build Status
dev Build Status

This repository is part of the larger Cloud Insurance Co. project.

Overview

Policy Bot

Deploy

In order to deploy the full set of microservices involved, check out the insurance-toolchain repo. Otherwise, you can deploy just the app by following the steps here.

Running the app on IBM Cloud

  1. If you do not already have a IBM Cloud account, sign up here

  2. Download and install the IBM Cloud CLI tool

  3. Clone the app to your local environment from your terminal using the following command:

    git clone https://github.com/IBM-Cloud/insurance-bot.git
    
  4. cd into this newly created directory

  5. Open the manifest.yml file and change the host value to something unique. The host you choose will determinate the subdomain of your application's URL: <host>.mybluemix.net

  6. Connect to IBM Cloud in the command line tool and follow the prompts to log in. Download and setup IBM Cloud CLI

    ibmcloud login
    

    Use ibmcloud target --cf to set org and space; Run ibmcloud regions to find API endpoints.

  7. Create a Cloudant service in IBM Cloud

    ibmcloud cf create-service cloudantNoSQLDB Lite insurance-bot-db
    
  8. Create a Watson Assistant (formerly Conversation) service in IBM Cloud

    ibmcloud cf create-service conversation free insurance-bot-conversation
    
  9. Create an App ID service in IBM Cloud

    ibmcloud service create appid "Graduated tier" insurance-bot-appid
    
  10. Push the app to IBM Cloud

    ibmcloud cf push
    

And voila! You now have your very own instance of the app running on IBM Cloud.

Run the app locally

  1. If you do not already have a IBM Cloud account, sign up here

  2. If you have not already, download Node.js and install it on your local machine.

  3. Create a Cloudant service in IBM Cloud

    ibmcloud cf create-service cloudantNoSQLDB Lite insurance-bot-db
    
  4. Create a Watson Assistant (formerly Conversation) service in IBM Cloud

    ibmcloud cf create-service conversation free insurance-bot-conversation
    
  5. Create an App ID service in IBM Cloud

    ibmcloud service create appid "Graduated tier" insurance-bot-appid
    
  6. In the checkout directory, copy the file vcap-local.template.json to vcap-local.json. Edit vcap-local.json and update the credentials for the Cloudant and Watson Assistant (formerly Conversation) services. You can retrieve the service credentials from the IBM Cloud console.

    cp vcap-local.template.json vcap-local.json
    
  7. Install the dependencies

    npm install
    
  8. Run the app locally

    npm start
    

Improvements

For continuous improvements, refer to the additional improvement section.

Cleanup

See the Cleanup section in the toolchain repository for instructions on how to remove the resources associated with the entire project.

Contribute

If you find a bug, please report it via the Issues section or even better, fork the project and submit a pull request with your fix! We are more than happy to accept external contributions to this project if they address something noted in an existing issue. In order to be considered, pull requests must pass the initial Travis CI build and/or add substantial value to the sample application.

Troubleshooting

The primary source of debugging information for your IBM Cloud app is the logs. To see them, run the following command using the Cloud Foundry CLI:

$ cf logs insurance-bot --recent

For more detailed information on troubleshooting your application, see the Troubleshooting section in the IBM Cloud documentation.

License

See License.txt for license information.


Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
css (7,156
nodejs (3,568
demo (471
chatbot (282
cloud-foundry (26
ibm-cloud (19

Find Open Source By Browsing 7,000 Topics Across 59 Categories