Skip to content

Commit

Permalink
update helpdesk logic to use Jira personal access tokens (#712)
Browse files Browse the repository at this point in the history
bonus:
- improved error handling to reduce crashes in other areas (captcha, eslint clients)
- heaps of logging (including debug mode #rejoice)
- add ‘@/‘ to absolute paths to match current community/industry practices.
  • Loading branch information
justincorrigible authored Jan 23, 2024
1 parent 32dc68c commit 3583591
Show file tree
Hide file tree
Showing 18 changed files with 1,365 additions and 1,203 deletions.
21 changes: 8 additions & 13 deletions .schema.env → .env.schema
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PORT=9000
ADVERTISED_HOST=http://localhost:9000
DEBUG_LOGGING=false # turns on `debug` level logging in production

# elasticsearch
ELASTICSEARCH_HOST=http://localhost:9200
Expand Down Expand Up @@ -60,28 +61,22 @@ DONOR_AGGREGATOR_API_ROOT=
DATA_CENTER_REGISTRY_API_ROOT=

# Jira Helpdesk
JIRA_ADMIN_VAULT_CREDENTIALS_PATH =
JIRA_REST_URI =
JIRA_SERVICEDESK_ID = 9

# For local testing only, fallback values if USE_VAULT = FALSE
JIRA_ADMIN_EMAIL=
JIRA_ADMIN_PASS=

# Optional
JIRA_ORGANIZATION_ID=
JIRA_ADMIN_VAULT_CREDENTIALS_PATH=
JIRA_REST_URI=
JIRA_SERVICEDESK_ID= 9
JIRA_PERSONAL_ACCESS_TOKEN= # PAT is used only when USE_VAULT is false
JIRA_ORGANIZATION_ID= # Optional

# feature flags
FEATURE_ARRANGER_SCHEMA_ENABLED=false
FEATURE_METADATA_ACCESS_CONTROL=false
FEATURE_HELP_DESK_ENABLED=false

# recaptcha configs
## set this to true for local development if you don't want to use real recaptcha client
DEV_RECAPTCHA_DISABLED=false
DEV_RECAPTCHA_DISABLED=false # set true for stub/dev recaptcha client
RECAPTCHA_SECRET_KEY=
RECAPTCHA_VAULT_SECRET_PATH=

# system alerts
## use a JSON string. [{title:'',message:'',dismissable:true|false,id:'unique-string',alert:'warning'|'error'|'info'}]
SYSTEM_ALERTS=
SYSTEM_ALERTS=
6 changes: 3 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module.exports = {
parserOptions: {
ecmaVersion: 'latest',
extraFileExtensions: ['.json'],
project: ['./tsconfig.json'],
project: ['./tsconfig.json', './tsconfig.eslint.json'],
},
plugins: ['@typescript-eslint', 'prettier'],
root: true,
Expand Down Expand Up @@ -47,10 +47,10 @@ module.exports = {
'prettier/prettier': [
'error',
{
printWidth: 100,
trailingComma: 'all',
printWidth: 120,
semi: true,
singleQuote: true,
trailingComma: 'all',
useTabs: true,
},
],
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ typings/
.yarn-integrity

# dotenv environment variables file
.env
# only .env will actually be loaded
*.env*
!**/.env.schema

# next.js build output
.next
Expand Down
Loading

0 comments on commit 3583591

Please sign in to comment.