Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Digital Ocean managed BD agent throws an error #21

Closed
djleonskennedy opened this issue Oct 25, 2023 · 1 comment
Closed

Digital Ocean managed BD agent throws an error #21

djleonskennedy opened this issue Oct 25, 2023 · 1 comment

Comments

@djleonskennedy
Copy link

Hello @TimoGlastra @2mau

Could you please help with?

Trying to use DO database, and seems Asker cannot create databases there

openwallet-foundation/credo-ts#1614

2023-10-25 09:03:12.659  INFO  [DIDComm Chat   WalletApi.initialize] Initializing wallet 'incogme-mediator-beta' 
{
  id: 'incogme-mediator-beta',
  key: '[*****]',
  storage: {
    type: 'postgres',
    config: {
      host: 'beta-incogme-db-postgresql-fra1-do-user-13941840-0.c.db.ondigitalocean.com:25060',
      connectTimeout: 10
    },
    credentials: '[*****]'
  }
}
2023-10-25 09:03:13.146  DEBUG [DIDComm Chat   AskarWallet._open] Wallet 'incogme-mediator-beta' not found 
2023-10-25 09:03:13.146  DEBUG [DIDComm Chat   AskarWallet.createAndOpen] Creating wallet 'incogme-mediator-beta 
2023-10-25 09:03:14.294  ERROR [DIDComm Chat   AskarWallet.createAndOpen] Error creating wallet 'incogme-mediator-beta' 
{
  error: {
    stack: 'Error: Backend error\n' +
      'Caused by: error returned from database: database "postgres" does not exist\n' +
      '    at cb (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@hyperledger/aries-askar-nodejs/build/NodeJSAriesAskar.js:44:39)\n' +
      '    at Object.<anonymous> (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/ffi-napi/lib/callback.js:66:27)',
    message: 'Backend error\n' +
      'Caused by: error returned from database: database "postgres" does not exist',
    code: 1
  },
  errorMessage: 'Backend error\n' +
    'Caused by: error returned from database: database "postgres" does not exist'
}

/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/askar/build/wallet/AskarWallet.js:114
            throw new core_1.WalletError(errorMessage, { cause: error });
                  ^
WalletError: Error creating wallet 'incogme-mediator-beta'
    at AskarWallet.createAndOpen (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/askar/build/wallet/AskarWallet.js:114:19)
    at async WalletApi.createAndOpen (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/core/build/wallet/WalletApi.js:63:9)
    at async WalletApi.initialize (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/core/build/wallet/WalletApi.js:54:17)
    at async Agent.initialize (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/core/build/agent/BaseAgent.js:89:13)
    at async Agent.initialize (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@aries-framework/core/build/agent/Agent.js:124:9)
    at async createAgent (/Users/yuriyyakovenko/projects/incogme/mediator/build/agent.js:107:5) {
  [cause]: AriesAskarError: Backend error
  Caused by: error returned from database: database "postgres" does not exist
      at cb (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/@hyperledger/aries-askar-nodejs/build/NodeJSAriesAskar.js:44:39)
      at Object.<anonymous> (/Users/yuriyyakovenko/projects/incogme/mediator/node_modules/ffi-napi/lib/callback.js:66:27) {
    code: 1,
    extra: undefined
  }
}

Node.js v18.17.0
error Command failed with exit code 1.

Regards

@djleonskennedy
Copy link
Author

Solution: postgres database should be created manualy (use PGAdmin)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant