项目作者: austinheap

项目描述 :
A package for accessing InfluxDB from Laravel 5.5+, based on configuration settings.
高级语言: PHP
项目地址: git://github.com/austinheap/laravel-database-influxdb.git
创建时间: 2017-11-16T05:22:54Z
项目社区:https://github.com/austinheap/laravel-database-influxdb

开源协议:

下载


Laravel 5.5+ InfluxDB Database Package

Current Release
Total Downloads
Build Status
Dependency Status
Scrutinizer CI
StyleCI
Maintainability
Test Coverage
SensioLabs

A package for accessing InfluxDB from Laravel 5.5+, based on configuration settings.

There is documentation for laravel-database-influxdb online,
the source of which is in the docs/
directory. The most logical place to start are the docs for the InfluxDbServiceProvider class.

Installation

Step 1: Composer

Via Composer command line:

  1. $ composer require austinheap/laravel-database-influxdb

Or add the package to your composer.json:

  1. {
  2. "require": {
  3. "austinheap/laravel-database-influxdb": "0.1.*"
  4. }
  5. }

Step 2: Enable the package (Optional)

This package implements Laravel 5.5’s auto-discovery feature. After you install it the package provider and facade are added automatically.

If you would like to declare the provider and/or alias explicitly, then add the service provider to your config/app.php:

  1. 'providers' => [
  2. //
  3. AustinHeap\Database\InfluxDb\InfluxDbServiceProvider::class,
  4. ];

And then add the alias to your config/app.php:

  1. 'aliases' => [
  2. //
  3. 'InfluxDb' => AustinHeap\Database\InfluxDb\InfluxDbFacade::class,
  4. ];

Step 3: Configure the package

Publish the package config file:

  1. $ php artisan vendor:publish --provider="AustinHeap\Database\InfluxDb\InfluxDbServiceProvider"

You may now place your defaults in config/influxdb.php.

Full .env Example

To override values in config/influxdb.php, simply add the following to your .env file:

  1. INFLUXDB_PROTOCOL=https
  2. INFLUXDB_USER=my-influxdb-user
  3. INFLUXDB_PASS=my-influxdb-pass
  4. INFLUXDB_HOST=my-influxdb.server

References

Credits

This is a fork of pdffiller/laravel-influx-provider.

License

The MIT License (MIT). Please see License File for more information.