Comments (5)
@larenelg You're a legend. Had to switch the default host from '127.0.0.1' to 'seq-input-gelf' though when using docker. Would be great to have a Monolog plugin for the Seq HTTP API. Most devs i know use an external SaaS (pricey) or Graylog (requires Mongo and Elastic).
For others who are looking to implement this, had to make some changes to config/logging.php
, so here is the full snippet:
'seq' => [
'driver' => 'custom',
'via' => \Hedii\LaravelGelfLogger\GelfLoggerFactory::class,
'processors' => [
\Hedii\LaravelGelfLogger\Processors\NullStringProcessor::class,
],
'level' => env('GELF_MIN_LEVEL', 'debug'),
'name' => env('GELF_CHANNEL', 'your-app-name'),
'system_name' => env('GELF_SOURCE', 'laravel'),
'host' => env('GELF_HOST', '127.0.0.1'), // 'seq-input-gelf' when dockerised, not localhost
'port' => env('GELF_PORT', 12201),
'path' => env('GELF_HTTP_PATH', null),
'max_length' => null,
'context_prefix' => null,
'extra_prefix' => null,
],
from seq-input-gelf.
Be my guest! It's a bit thin on the ground in terms of docs tbh. This was the only package i found, but it's abandoned: https://github.com/msschl/monolog-seq-handler
I don't want to have to install Mongo/ES for Graylog - we need a nice team solution where we can watch API clients in real time, not have to SSH in for logs, and not send data across the net (even queued).
It makes it a whole new thing IMO. Particularly as you can log to the same place from different types of apps (e.g. Electron, Django, NoSQL DB etc).
from seq-input-gelf.
Hi @azcoppen
Thanks for getting in touch, and for the detailed information! I was able to reproduce your issue.
The reason why seq-input-gelf
cannot see seq
is because is not on one of the networks, frontend
or backend
.
I listed backend
as one of the networks under seq-input-gelf
and it resolved the issue.
Please let me know, or close this issue, if this also fixes it for you!
Here is my docker-compose.yml
for reference :)
version: '3'
services:
seq-input-gelf:
image: datalust/seq-input-gelf:latest
depends_on:
- seq
environment:
GELF_ADDRESS: "tcp://0.0.0.0:12201"
SEQ_ADDRESS: "http://seq:5341"
GELF_ENABLE_DIAGNOSTICS: "True"
ports:
- "12201:12201"
networks:
- backend
restart: unless-stopped
seq:
container_name: seq
image: datalust/seq:latest
restart: unless-stopped
environment:
- ACCEPT_EULA=y
ports:
- "9595:80"
- "5341:5341"
networks:
- frontend
- backend
networks:
frontend:
backend:
Cheers,
Larene
from seq-input-gelf.
@larenelg Thanks for the comprehensive and speedy response! Let me run it and see. Going to have a happy dev team if it does!
from seq-input-gelf.
Thanks for sharing that config @azcoppen - I hope you don't mind if we add a "logging from Laravel" section in our docs with similar config as an example (with due credit, of course!). It's been a while since I've built something using Laravel :)
RE: a Monolog plugin - bandwidth is a little thin on our team at the moment, but it does sound worthwhile! I might have a go at it myself, but if you are feeling like dabbling, here's an easy-to-follow tutorial on how to make a custom Seq Input Apps :) https://docs.datalust.co/docs/writing-custom-inputs
from seq-input-gelf.
Related Issues (20)
- Ingestion failed: Invalid URI: The URI scheme is not valid. HOT 3
- Spurious error logs when diagnostics enabled with TLS HOT 2
- control charater found while parsing a string HOT 1
- invalid unicode code point ? HOT 5
- select another timestamp key HOT 2
- Filter out "Empty" information messages HOT 2
- bin/sqelf: No such file or directory HOT 3
- The App Process is Stopped HOT 1
- Connection to Seq using gelf refusing HOT 1
- Add HTTP support HOT 2
- High memory consumption HOT 1
- All events from Docker Imported as Error Level in Seq HOT 6
- Add support for docker secrets HOT 2
- GELF processing failed HOT 8
- sqelf in Docker doesn't listen on 12201/TCP HOT 4
- "GELF processing failed irrecoverably" stops the receiver HOT 7
- ARM64 container for seq-input-gelf HOT 7
- "No template provided" HOT 14
- Question: Regex transformation of message possible? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from seq-input-gelf.