Skip to content

Micro-service to create and manage programs, like a contribution program, etc.

License

Notifications You must be signed in to change notification settings

vaivk369/program-service

This branch is 74 commits behind Sunbird-coKreat/program-service:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

a419e02 · Dec 5, 2023
Jan 5, 2021
Apr 15, 2021
Dec 5, 2023
Jun 25, 2020
Mar 9, 2020
May 18, 2023
Feb 16, 2021
Mar 9, 2020
Mar 22, 2022
Jun 15, 2021
Mar 12, 2020
May 5, 2021
Dec 26, 2022
Jan 5, 2021

Repository files navigation

Installing Contribution/Program Service on Local Laptop or Desktop

Pre-requisites

  1. Before you install program service on your laptop, examine your environment and gather data to ensure an optimal installation experience. Review the details to ensure that the environment has the necessary resources and compliant target systems to successfully install and run Program Service.

  2. Program service uses Postgres database to store and manage data. Refer programs.sql for the database and table structure.

Project Setup

  1. Clone the project

        git clone {SSH URL of FORKED REPOSITORY}
        cd {PROJECT-FOLDER}
        git remote add upstream git@github.com:Sunbird-Ed/program-service.git
        git fetch upstream
        git checkout -b {LOCAL-BRANCH-NAME} upstream/{LATEST BRANCH}

    Note: Stable versions of the program service are available via tags for each release, and the master branch contains latest stable release. For latest stable release refer

  2. Install Git Submodules to make use of https://github.com/project-sunbird/sunbird-js-utils.git

        cd {PROJECT-FOLDER}
        git submodule init
        git submodule update
  3. Install required dependencies

        cd {PROJECT-FOLDER}/src
        npm install
  4. Configuring the Environment

    • Open the file {PROJECT-FOLDER}/src/envVariables.js in any available text editor and update the contents of the file so that it contains exactly the following values
    const envVariables = {
    baseURL: process.env.dock_base_url || <'https://<host for adopter's instance'>,
    SUNBIRD_URL: process.env.sunbird_base_url || <'https://<host for adopter's instance'>,
    ....
    config: {
        user: process.env.sunbird_program_db_user || "<postgress user>",
        host: process.env.sunbird_program_db_host || "localhost",
        database: process.env.sunbird_program_db_name || 'sunbird_programs',
        password: process.env.sunbird_program_db_password || '<postgress password>',
       ....
    },
    }

    Once the file is updated with appropriate values, then you can proceed with running the application

Running Application

  1. Run the following command in the {PROJECT-FOLDER}/src folder
    node app.js
  1. The local HTTP server is launched at http://localhost:6000

About

Micro-service to create and manage programs, like a contribution program, etc.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published