Skip to content

Commit

Permalink
Archived old repo. To request old repo, please send an email to commu…
Browse files Browse the repository at this point in the history
  • Loading branch information
Ravi Prakash committed Jul 23, 2024
0 parents commit 2dfd973
Show file tree
Hide file tree
Showing 1,057 changed files with 125,292 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
project: 'tsconfig.json',
tsconfigRootDir: __dirname,
sourceType: 'module',
},
plugins: ['@typescript-eslint/eslint-plugin'],
extends: [
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended',
],
root: true,
env: {
node: true,
jest: true,
},
ignorePatterns: ['.eslintrc.js'],
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
},
};
166 changes: 166 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,166 @@
# compiled output
/dist
/node_modules

# Logs
logs
*.log
npm-debug.log*
pnpm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# OS
.DS_Store

# Tests
/coverage
/.nyc_output

# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json

# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.pnpm-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Snowpack dependency directory (https://snowpack.dev/)
web_modules/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional stylelint cache
.stylelintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variable files
.env
.env.development.local
.env.test.local
.env.production.local
.env.local

# parcel-bundler cache (https://parceljs.org/)
.cache
.parcel-cache

# Next.js build output
.next
out

# Nuxt.js build / generate output
.nuxt
dist

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and not Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# vuepress build output
.vuepress/dist

# vuepress v2.x temp and cache directory
.temp
.cache

# Docusaurus cache and generated files
.docusaurus

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Stores VSCode versions used for testing VSCode extensions
.vscode-test

# yarn v2
.yarn/cache
.yarn/unplugged
.yarn/build-state.yml
.yarn/install-state.gz
.pnp.*
1 change: 1 addition & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{ "semi": true, "trailingComma": "all", "singleQuote": false, "printWidth": 180, "tabWidth": 4, "arrowParens": "avoid" }
16 changes: 16 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
FROM node:18.14.0-alpine3.17

RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app

COPY package*.json ./
COPY . ./

RUN ls -ltrh

RUN npm install
RUN npm i -g pm2
RUN npm run build

EXPOSE 3000
CMD [ "pm2-runtime", "ecosystem.config.js" ]
28 changes: 28 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
pipeline {
agent any
stages {
stage('Executing Shell Script On Server') {
steps {
script {
sshagent(credentials: ['"${credentials}"']) {
sh '''
ssh -t -t ${userName}@${hostIP} -o StrictHostKeyChecking=no << EOF
${listOfCommands}
logout
EOF'''
}
}
}
}
}
post {
always {
cleanWs(cleanWhenNotBuilt: false,
deleteDirs: true,
disableDeferredWipeout: true,
notFailBuild: true,
patterns: [[pattern: '.gitignore', type: 'INCLUDE'],
[pattern: '.propsfile', type: 'EXCLUDE']])
}
}
}
22 changes: 22 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
MIT License

Copyright (c) 2022 Beckn

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

95 changes: 95 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
## TL;DR

- Set BPP Client URL and Base URL in .env
- Run `npm install` and `npm run start:dev` to start sandbox
- Set the `client.webhook.url` field in BPP Client config/default.yml to the address of this sandbox installation. (Previously you needed to configure a software called beckn-sandbox-webhook. That software is not required anymore.)

## Project Introduction/Overview

A sandbox environment typically replicates the necessary components of the production system but operates independently. It may include a separate server, database, network, and other resources. By isolating the sandbox environment from the production system, any errors, bugs, or vulnerabilities discovered during testing can be addressed without affecting live users or critical data.

## Release Notes

Latest version: 1.1.0

<!--
--Previous versions: Table having version number hyperlinked to Wiki page.
<Please follow a Tabular structure>
<Wiki Page of previous versions to have details such as Version number and corresponding features released>
-->

## Installation/Setup and User Guide

You can access the Installation/Setup and User Guide details from [here](https://github.com/beckn/beckn-sandbox/blob/main/USER_GUIDE.md).

<!--
## Link to Experience Center
<Links to various environments of Experience Center to be listed here>
## Link to FRS document
<Wiki Page to have all the details for FRS; include Wiki page link here>
## Link to Test cases
< Details to be added to a new Wiki page and link to be included here >
-->

<!--
## License information
< License details to be added here >
## Contributing guidelines
< Contributor guidelines to be added in a Wiki Page and link to be included here >
-->

## Architecture Diagrams/Technical Overview

You can access the Architecture Diagrams and Technical Details [here](https://github.com/beckn/beckn-sandbox/blob/main/USER_GUIDE.md#Sandbox-Architecture).

## Link to Postman Collections

You can access the Postman Collection details [here](https://github.com/beckn/beckn-sandbox/blob/main/USER_GUIDE.md#Import-Collection-in-Postman).

<!--
## Applicable use cases
<Mention the applicable use cases of the application, if any>
## Gateway
<Mention the gateway details and links if applicable>
-->

## Registry

You can access the Registry Details [here](https://github.com/beckn/beckn-sandbox/blob/main/USER_GUIDE.md#Setting-Up-Instances-of-Protocol-Server).

<!--
## Sandbox
<Mention the sandbox details if applicable>
## Link to demos
<Mention the demo details/links if applicable>
## Environments
<Mention the environment details and links>
## Deployment
<Mention the deployment details and links>
## Related Repositories
<Mention the related repositories for the project, dependent repositories, backend APIs, hosting details and links>
## Related URLs
<Mention the related URLs for the repositories / project>
-->

## Troubleshooting Steps

You can access the Troubleshooting Steps [here](https://github.com/beckn/beckn-sandbox/blob/main/TROUBLESHOOT_GUIDE.md).

## Team Contact information

For technical support or issues related to installation, contact the following contributors:

1. https://github.com/shreyvishal
2. https://github.com/shenoyninad
Loading

0 comments on commit 2dfd973

Please sign in to comment.