Giter Site home page Giter Site logo

Comments (4)

dwerder avatar dwerder commented on July 29, 2024

Hi @confiq ,

thats a little bit tricky at the moment. Because the graphite module has a built-in apache install routin. You have to disable it and use the puppetlabs/apache module.

Example:

  include '::apache'

  apache::vhost { graphite.my.domain:
    port    => '80',
    docroot => '/opt/graphite/webapp',
    wsgi_application_group      => '%{GLOBAL}',
    wsgi_daemon_process         => 'graphite',
    wsgi_daemon_process_options => {
      processes          => '5',
      threads            => '5',
      display-name       => '%{GROUP}',
      inactivity-timeout => '120',
    },
    wsgi_import_script          => '/opt/graphite/conf/graphite.wsgi',
    wsgi_import_script_options  => {
      process-group     => 'graphite',
      application-group => '%{GLOBAL}'
    },
    wsgi_process_group          => 'graphite',
    wsgi_script_aliases         => {
      '/' => '/opt/graphite/conf/graphite.wsgi'
    },
    headers => [
        'set Access-Control-Allow-Origin "*"',
        'set Access-Control-Allow-Methods "GET, OPTIONS, POST"',
        'set Access-Control-Allow-Headers "origin, authorization, accept"',
     ],
    directories => [{
      path => '/media/',
      order => 'deny,allow',
      allow => 'from all'}
    ]
  }->
 class { 'graphite':
   gr_web_server => 'none'
 }

  apache::vhost { 'grafana.my.domain':
    servername      => 'grafana.my.domain',
    port            => 80,
    docroot         => '/opt/grafana',
    error_log_file  => 'grafana_error.log',
    access_log_file => 'grafana_access.log',
    directories     => [
      {
        path            => '/opt/grafana',
        options         => [ 'None' ],
        allow           => 'from All',
        allow_override  => [ 'None' ],
        order           => 'Allow,Deny',
      }
    ]
  }->
  class {'grafana':
    graphite_host      => 'graphite.my.domain',
    elasticsearch_host => 'elasticsearach.my.domain',
    elasticsearch_port => 9200,
  }

I hope that fixes you problem.

from puppet-grafana.

confiq avatar confiq commented on July 29, 2024

Yes, after little research i've understand that I should use class { 'graphite': gr_web_server => 'none'} and have my own vhost.

Thanks @dwerder it helped!

from puppet-grafana.

dwerder avatar dwerder commented on July 29, 2024

The next major version 6 will use the puppetlabs/apache module if you use gr_web_server => 'apache' and the default will become 'none'. So that you can provide your own webserver config.

Regards

from puppet-grafana.

confiq avatar confiq commented on July 29, 2024

That sounds ideal.
My suggestion is to write in docs about this case
Thanks again @dwerder :)

EDIT: fix

from puppet-grafana.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.