Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/joreilly/peopleinspacegraphqlserver
Cloud Run based GraphQL backend for PeopleInSpace supporting queries and subscriptions
https://github.com/joreilly/peopleinspacegraphqlserver
graphql graphql-server kotlin
Last synced: 18 days ago
JSON representation
Cloud Run based GraphQL backend for PeopleInSpace supporting queries and subscriptions
- Host: GitHub
- URL: https://github.com/joreilly/peopleinspacegraphqlserver
- Owner: joreilly
- License: apache-2.0
- Created: 2022-01-20T18:48:26.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-02-11T15:54:07.000Z (almost 3 years ago)
- Last Synced: 2023-03-03T23:12:33.897Z (over 1 year ago)
- Topics: graphql, graphql-server, kotlin
- Language: Kotlin
- Homepage:
- Size: 73.2 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PeopleInSpace GraphQL Server
GraphQL backend allowing querying list of people in space and subscribing to position of International Space Station.
## Run Locally:
1. Start the local server: `./gradlew bootRun`
1. Open: [localhost:8080/playground](http://localhost:8080/playground)## Run on Google Cloud Run (with the command line):
1. [Install & setup gcloud](https://cloud.google.com/sdk/install)
1. Enable the Container, Container Registry, Cloud Build, and Cloud Run APIs:
```
gcloud services enable container.googleapis.com containerregistry.googleapis.com cloudbuild.googleapis.com run.googleapis.com
```1. Build the container image on Cloud Build using Buildpacks, storing the image on Google Container Registry:
```
export PROJECT_ID=YOUR_GCP_PROJECT_ID
gcloud builds submit --pack=image=gcr.io/$PROJECT_ID/peopleinspace-graphql
```1. Deploy on Google Cloud Run:
```
gcloud run deploy \
--image=gcr.io/$PROJECT_ID/peopleinspace-graphql \
--platform=managed \
--allow-unauthenticated \
--project=$PROJECT_ID \
--region=us-central1 \
--memory=1Gi \
peopleinspace-graphql
```## Local Docker Build & Run
1. [Install Docker](https://docs.docker.com/get-docker/)
1. Build the image
```
./gradlew bootBuildImage --imageName=peopleinspace-graphql
```1. Run image:
```
docker run -p8080:8080 peopleinspace-graphql
```1. Open: [localhost:8080/playground](http://localhost:8080/playground)