mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Added influxdb docker block, and fixed issue when adding data source
This commit is contained in:
parent
83d798dbad
commit
ea8307f79e
16
docker/blocks/influxdb/Dockerfile
Normal file
16
docker/blocks/influxdb/Dockerfile
Normal file
@ -0,0 +1,16 @@
|
||||
# influxdb
|
||||
|
||||
FROM ubuntu
|
||||
|
||||
RUN mkdir -p /opt/influxdb/shared/data
|
||||
|
||||
ADD http://s3.amazonaws.com/influxdb/influxdb_0.8.8_amd64.deb /influx88.deb
|
||||
RUN dpkg -i /influx88.deb
|
||||
RUN rm -rf /opt/influxdb/shared/data
|
||||
|
||||
ADD config.toml /opt/influxdb/shared/config.toml
|
||||
|
||||
EXPOSE 8083 8086 2004
|
||||
|
||||
ENTRYPOINT ["/usr/bin/influxdb"]
|
||||
CMD ["-config=/opt/influxdb/shared/config.toml"]
|
75
docker/blocks/influxdb/config.toml
Normal file
75
docker/blocks/influxdb/config.toml
Normal file
@ -0,0 +1,75 @@
|
||||
bind-address = "0.0.0.0"
|
||||
|
||||
[logging]
|
||||
level = "debug"
|
||||
file = "/opt/influxdb/shared/data/influxdb.log" # stdout to log to standard out
|
||||
|
||||
[admin]
|
||||
port = 8083 # binding is disabled if the port isn't set
|
||||
assets = "/opt/influxdb/current/admin"
|
||||
|
||||
[api]
|
||||
port = 8086 # binding is disabled if the port isn't set
|
||||
|
||||
read-timeout = "5s"
|
||||
|
||||
[input_plugins]
|
||||
|
||||
[input_plugins.graphite]
|
||||
enabled = true
|
||||
port = 2004
|
||||
database = "graphite" # store graphite data in this database
|
||||
|
||||
|
||||
[raft]
|
||||
port = 8090
|
||||
dir = "/opt/influxdb/shared/data/raft"
|
||||
|
||||
[storage]
|
||||
dir = "/opt/influxdb/shared/data/db"
|
||||
# How many requests to potentially buffer in memory. If the buffer gets filled then writes
|
||||
# will still be logged and once the local storage has caught up (or compacted) the writes
|
||||
# will be replayed from the WAL
|
||||
write-buffer-size = 10000
|
||||
default-engine = "rocksdb"
|
||||
max-open-shards = 0
|
||||
point-batch-size = 100
|
||||
write-batch-size = 5000000
|
||||
retention-sweep-period = "10m"
|
||||
|
||||
[storage.engines.rocksdb]
|
||||
max-open-files = 1000
|
||||
lru-cache-size = "200m"
|
||||
|
||||
[storage.engines.leveldb]
|
||||
max-open-files = 1000
|
||||
lru-cache-size = "200m"
|
||||
|
||||
[cluster]
|
||||
protobuf_port = 8099
|
||||
protobuf_timeout = "2s" # the write timeout on the protobuf conn any duration parseable by time.ParseDuration
|
||||
protobuf_heartbeat = "200ms" # the heartbeat interval between the servers. must be parseable by time.ParseDuration
|
||||
protobuf_min_backoff = "1s" # the minimum backoff after a failed heartbeat attempt
|
||||
protobuf_max_backoff = "10s" # the maxmimum backoff after a failed heartbeat attempt
|
||||
write-buffer-size = 10000
|
||||
ax-response-buffer-size = 100000
|
||||
oncurrent-shard-query-limit = 10
|
||||
|
||||
[sharding]
|
||||
replication-factor = 1
|
||||
|
||||
[sharding.short-term]
|
||||
duration = "7d"
|
||||
split = 1
|
||||
|
||||
[sharding.long-term]
|
||||
duration = "30d"
|
||||
split = 1
|
||||
# split-random = "/^Hf.*/"
|
||||
|
||||
[wal]
|
||||
dir = "/opt/influxdb/shared/data/wal"
|
||||
flush-after = 1000 # the number of writes after which wal will be flushed, 0 for flushing on every write
|
||||
bookmark-after = 1000 # the number of writes after which a bookmark will be created
|
||||
index-after = 1000
|
||||
requests-per-logfile = 10000
|
6
docker/blocks/influxdb/fig
Normal file
6
docker/blocks/influxdb/fig
Normal file
@ -0,0 +1,6 @@
|
||||
influxdb:
|
||||
build: blocks/influxdb
|
||||
ports:
|
||||
- "2004:2004"
|
||||
- "8083:8083"
|
||||
- "8086:8086"
|
@ -1,18 +1,7 @@
|
||||
mysqltests:
|
||||
image: mysql:latest
|
||||
environment:
|
||||
MYSQL_ROOT_PASSWORD: rootpass
|
||||
MYSQL_DATABASE: grafana_tests
|
||||
MYSQL_USER: grafana
|
||||
MYSQL_PASSWORD: password
|
||||
influxdb:
|
||||
build: blocks/influxdb
|
||||
ports:
|
||||
- "3306:3306"
|
||||
|
||||
postgrestest:
|
||||
image: postgres:latest
|
||||
environment:
|
||||
POSTGRES_USER: grafanatest
|
||||
POSTGRES_PASSWORD: grafanatest
|
||||
ports:
|
||||
- "5432:5432"
|
||||
- "2004:2004"
|
||||
- "8083:8083"
|
||||
- "8086:8086"
|
||||
|
||||
|
@ -58,7 +58,6 @@ function (angular) {
|
||||
|
||||
backendSrv.put('/api/datasources', $scope.current)
|
||||
.then(function() {
|
||||
$scope.editor.index = 0;
|
||||
$scope.getDatasources();
|
||||
});
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user