Skip to content

anishshobithpsarchive/akto-app

Repository files navigation

akto-app

Description :

The app, runs a cron job every minute in the code and fetch's data from Github Public Repo and updates as changes reflected on the file.

How to run the akto-app

  1. Clone the project
git clone [email protected]:Anish-Shobith/akto-app.git

Note: I use ssh, you can use https over ssh.

  1. Change Directory
cd akto-app
  1. Install the dependencies (I use yarn hence)
yarn install
  1. Make necessary changes in the .env.example file for database connection. (That is provide a Database URL) and importantly rename .env.example to .env
DATABASE_URL="mongodb+srv://<username>:<password>@cluster0.ijkiuxr.mongodb.net/<dbname>?retryWrites=true&w=majority"

Note :
Replace <username> with your username.
Replace <password> with your password.
And Finally replace <dbname> with your dbname, you can keep akto-app.

I am using Mongodb Atlas, a Tutorial on setup of the Cluster can be found in here.

  1. Start the app, this will call the start script in the package.json, which
yarn start

Output:

Cron job started successfully.
... After 1 Minute
Data fetched and stored successfully.
... After 1 Minute
Data fetched and stored successfully.

If Error:

Error fetching and storing data: Error Information

Tech Stack

  • MongoDB Atlas
  • typescript (Programming Language)
  • prisma (Database ORM)
  • @octokit/rest (API to interact with GitHub)
  • winston (Logger)
  • yarn (Package Manager)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published