xk6-output-prometheus-remote
                                
                                 xk6-output-prometheus-remote copied to clipboard
                                
                                    xk6-output-prometheus-remote copied to clipboard
                            
                            
                            
                        feat: Add SigV4 support
Add SigV4 support for #93.
Environment variables:
- K6_PROMETHEUS_RW_SIGV4_AUTH: Enable SigV4 for AWS Managed Prometheus.
- K6_PROMETHEUS_RW_SIGV4_REGION: AWS region where the workspace is.
- K6_PROMETHEUS_RW_SIGV4_ACCESS_KEY: AWS access key.
- K6_PROMETHEUS_RW_SIGV4_SECRET_KEY: AWS secret key.
- K6_PROMETHEUS_RW_SIGV4_PROFILE: AWS profile to use.
- K6_PROMETHEUS_RW_SIGV4_ROLE_ARN: AWS role ARN to assume.
Note: Set AWS_SDK_LOAD_CONFIG to true for the shared config and credential files.
Looking at teh amount of dependancies this pulls in ... I am concerned.
I did a quick check and this adds 7mb on top of k6 for this one authentication. +Every security alert we get about all of those dependancies.
GIven that this currently goes in k6 core I really would prefer not to merge this.
Some quick googling shows that there are ways to get the authenticaiton without pulling in the whole aws sdk and I would recommend we actually go down this route
https://gist.github.com/anandkunal/b67eb94454b77cfc2b50026989586cc0
cc @codebien
edit:
$ xk6  build --output k6-remote-one  --with github.com/grafana/xk6-output-prometheus-remote@main
$ xk6 build --output k6-remove-sigv4  --with github.com/grafana/xk6-output-prometheus-remote=github.com/rybbchao/xk6-output-prometheus-remote@1b6d8863e4f3c1ce91b1419185faad6bb5d865db
$ ls -l k6-*
-rwxr-xr-x. 1 mstoykov mstoykov 37511320 Feb  8 18:03 k6-remote-one
-rwxr-xr-x. 1 mstoykov mstoykov 44818584 Feb  8 18:03 k6-remove-sigv4
Hey @rybbchao, I'm going to close this issue as it seems is not under active development. Feel free to re-open if you find the time to re-work the changes.
Thanks for your contribution :bow: