From 4243e5c51393035a969df3a55ed3779376407ea6 Mon Sep 17 00:00:00 2001 From: Cahllagerfeld <43843195+Cahllagerfeld@users.noreply.github.com> Date: Thu, 26 Aug 2021 12:50:04 +0200 Subject: [PATCH] feat: gitpodify (#600) * feat: init gitpod * feat: adjust gitpod.yml & docker-compose * feat: add prebuild * feat: Update .gitpod.yml Co-authored-by: David Leal * fix: Update .gitpod.yml Co-authored-by: David Leal * feat: Update .gitpod.yml Co-authored-by: David Leal Co-authored-by: Cahllagerfeld Co-authored-by: David Leal --- .gitpod.yml | 31 +++++++++++++++++++++++++++++++ docker-compose.yml | 28 ++++++++++++++++++++++++++++ package.json | 2 +- 3 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 .gitpod.yml create mode 100644 docker-compose.yml diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 00000000..9b95a2b4 --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,31 @@ +tasks: + - name: Stargate + command: docker-compose up stargate + - name: api + command: | + sleep 35 + docker-compose up eddiehub-api + - name: Eddiebot + init: | + npm i -g npm + npm install + gp await-port 3000 + command: npm run start:dev + +github: + prebuilds: + # enable for the default branch (defaults to true) + main: true + # enable for all branches in this repo (defaults to false) + branches: true + # enable for pull requests coming from this repo (defaults to true) + pullRequests: true + # enable for pull requests coming from forks (defaults to false) + pullRequestsFromForks: true + # add a check to pull requests (defaults to true) + addCheck: true + # add a "Review in Gitpod" button as a comment to pull requests (defaults to false) + addComment: false + # add a "Review in Gitpod" button to the pull request's description (defaults to false) + addBadge: true + diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 00000000..59082ab1 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,28 @@ +version: '3.9' +services: + stargate: + image: 'stargateio/stargate-3_11:v1.0.29' + ports: + - '8080:8080' + - '8081:8081' + - '8082:8082' + - '127.0.0.1:9042:9042' + environment: + - CLUSTER_NAME=stargate + - CLUSTER_VERSION=3.11 + - DEVELOPER_MODE=true + eddiehub-api: + image: ghcr.io/eddiehubcommunity/api:latest + ports: + - '3000:3000' + depends_on: + - stargate + environment: + - APPROVED_TOKENS=abc,def + - DEBUG=false + - JWT_SECRET=test-secret + - STARGATE_BASEURL=http://stargate:8082 + - STARGATE_BASE_API_PATH=/v2/namespaces + - STARGATE_AUTH_URL=http://stargate:8081/v1/auth + - STARGATE_USERNAME=cassandra + - STARGATE_PASSWORD=cassandra diff --git a/package.json b/package.json index 39d2b741..ac0390b3 100644 --- a/package.json +++ b/package.json @@ -87,4 +87,4 @@ "coverageDirectory": "../coverage", "testEnvironment": "node" } -} \ No newline at end of file +}