Table of Contents
This guide helps you run a local development setup that sets up both Space Cloud and Postgres. It lets you explore the GraphQL APIs of Space Cloud on Postgres without having to set up any frontend projects.
The spaceuptech/space-cloud/install-manifests repo contains all installation manifests required to deploy Space Cloud anywhere. Get the docker compose file from there:
You should be able to see a
docker-compose.yaml file with the following contents:
version: '3.6' services: postgres: image: postgres restart: always space-cloud: image: spaceuptech/space-cloud ports: - "4122:4122" - "4126:4126" depends_on: - "postgres" restart: always environment: ## The DEV environment lets you use Mission Control (Admin UI) without login ## Change the dev mode to false if you want a login to your Mission Control UI DEV: "true" ## Uncomment next lines to change the login credentials of Mission Control UI # ADMIN_USER: "admin" # ADMIN_PASS: "123" # ADMIN_SECRET: "some-secret" # This is the JWT secret used for login authentication in Mission Control
docker-compose up -d
Check if the containers are running:
If you exec into docker container of Space Cloud, you can see a
config.yaml file generated by Space Cloud in the home directory.
Space Cloud needs this config file to function. The config file is used to load information like the database to be used, its connection string, security rules, etc.
Space Cloud has it’s own Mission Control (admin UI) to configure all of this quickly.
Head over to http://localhost:4122/mission-control to open Mission Control.
localhostwith the address of your Space Cloud if you are not running it locally.
Create a Project button to open the following screen:
name to your project.
Select POSTGRESQL as your database.
Next to create the project.
Head over to the
As you can see, the connection status would be disconnected.
Click on the
Edit Connection button:
Copy-paste the following connection string in it:
That’s all that is required to configure Space Cloud for this guide!
Our backend is up and running, configured to expose APIs on Postgres. Time to explore its awesome powers.
Explore GraphQL APIs of Space Cloud using GraphiQL.