diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 0000000000..f88d814f81 --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,13 @@ +tasks: + - init: > + test -f go.mod && go get -v ./...; + wget https://github.com/prometheus/prometheus/releases/download/v2.22.2/prometheus-2.22.2.linux-amd64.tar.gz --directory-prefix=/tmp; + cd /tmp && tar xvfz prometheus-*.tar.gz && rm prometheus-*.tar.gz; + mv prometheus-*/prometheus /workspace/go/bin/; + wget https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh && chmod u+x ./wait-for-it.sh && cd /workspace/thanos/scripts && mv /tmp/wait-for-it.sh .; + ./quickstart.sh; + for i in {0..2};do ./wait-for-it.sh -q localhost:909"$i" -- && echo "Prometheus instance no.$((i+1)) localhost:909$i is up"; done; + ./wait-for-it.sh localhost:10914 -- && echo "Thanos frontend at localhost:10914 is up"; +ports: + - port: 10914 + onOpen: open-preview diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 074e7968f1..0d4f9696f7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -84,6 +84,8 @@ component of the Thanos distributed system. We recommend: * Familiarizing yourself with our [coding style guidelines.](docs/contributing/coding-style-guide.md). * Familiarizing yourself with the [Makefile](Makefile) commands, for example `format`, `build`, `proto`, `docker` and `test`. `make help` will print most of available commands with details. +* Spin up a prebuilt dev environment using Gitpod.io +[![Gitpod Ready-to-Code](https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod)](https://gitpod.io/#https://github.com/thanos-io/thanos) ### Pull Request Process diff --git a/README.md b/README.md index 6ba5875ec2..bff36f0343 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,7 @@ [![go](https://github.com/thanos-io/thanos/workflows/go/badge.svg)](https://github.com/thanos-io/thanos/actions?query=workflow%3Ago) [![react](https://github.com/thanos-io/thanos/workflows/react/badge.svg)](https://github.com/thanos-io/thanos/actions?query=workflow%3Areact) [![docs](https://github.com/thanos-io/thanos/workflows/docs/badge.svg)](https://github.com/thanos-io/thanos/actions?query=workflow%3Adocs) +[![Gitpod ready-to-code](https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod)](https://gitpod.io/#https://github.com/thanos-io/thanos) ## Overview