jkordish / s3post.rs

Take logs from stdin then compress and send to S3.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

s3post.rs Build Status

Take logs from stdin then compress and send to S3.

Ideally you could couple this with a syslog remote server for the collection of all logs from systems pointed at it.

config

{
  "cachedir": "/tmp/s3post",
  "role_arn": "arn:aws:iam::<account>:role/<name>",
  "region": "us-west-2",
  "bucket": "<bucket>",
  "prefix": "logs",
  "logfile": "s3post.log"
}

Based off of the example config the logfile will be /tmp/s3post/s3post.log

building

$ curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain nightly
$ git clone https://github.com/jkordish/s3post.rs.git
$ cd s3post.rs
$ cargo build --release

Binary will be target/release/s3post

simple install

$ curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain nightly
$ cargo install --git https://github.com/jkordish/s3post.rs.git

About

Take logs from stdin then compress and send to S3.

License:MIT License


Languages

Language:Rust 96.9%Language:Shell 3.1%