1.0.0 • Published 2 years ago

pdq-core v1.0.0

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

pdq-core

Welcome.

First steps:

  1. Run npm install
  2. Node version should be v12.18.0
  3. Compile the project with npm run tsc
  4. Have local mysql running.
  5. Create local database pdq_db (Or a different name that you want)
  6. Add .env file as follows: (Make sure that user + password + port + db are matching your setup)
    DB_USER=
    DB_PASSWORD=
    DB_HOST=127.0.0.1
    DB_PORT=3306
    DB=pdq_db
    CACHE_PREFIX=abc
    NEW_RELIC_ENABLED=false
    NEW_RELIC_NO_CONFIG_FILE=true
    GOOGLE_API_KEY=AIzaSyAMHzAIGi_ZNNLEVryRUTyb4jIs2bYmTns
    SLACK_SIGNING_SECRET_TEST=e9d6fa5dc337bc6d009ab733b74dae04
    SLACK_BOT_TOKEN_TEST=xoxb-1436612971252-1841863939735-8XB5LwBRsOfXpp1KPCQJvXTq
    SLACK_SIGNING_SECRET_PROD=94df9d18cf85e0eafa60d69bc6499df0
    SLACK_BOT_TOKEN_PROD=xoxb-1436612971252-1520939522129-ngTUQA96bgqCUbbUAu7arIyP
  1. Import pdq.db database sql dump into your databse that you created in step 5 - here
  2. Run the project with node app.js

Project will run on localhost:8080 and will show:

undefined
Production: undefined
Connection to: 127.0.0.1 pdq_db
Loaded streets list
info created Database connection
info App is listening on port 8080

Use Postman / Local front Angular code to make api calls to pdq-core pdq-core expects pdqsession header sent with every api request. pdqsession content is the value of the cookie from the web browser cookie of pdq.

pdq-core with docker

DOCKER_README.md