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

provide credentials by passing the username and password parameters for elastic user #707

Open
rezacloner1372 opened this issue Jan 30, 2023 · 0 comments

Comments

@rezacloner1372
Copy link

how can I provide a username and password in my code? I don't find anything related to this

if (_.get(logConfig, 'elastic.enable')) {
  const Elasticsearch = require('bunyan-elasticsearch')
  const {Client} = require('elasticsearch')
  const client = new Client({host: logConfig.elastic.host})
  const {myindexMapping} = require('./util/mapping')

  const esStream = new Elasticsearch({
    indexPattern: '[myindex-]YYYY.MM.DD',
    type: 'logs',
    host: logConfig.elastic.host
  })
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