|
| 1 | +--- |
| 2 | +title: Create a deployment |
| 3 | +permalink: /getting-started/cloud/create-a-deployment |
| 4 | +category: Getting Started |
| 5 | +subCategory: Cube Cloud |
| 6 | +menuOrder: 3 |
| 7 | +--- |
| 8 | + |
| 9 | +In this step, we will create a new deployment in Cube Cloud. A deployment |
| 10 | +represents a data model, configuration, and managed infrastructure. We will use |
| 11 | +it to connect a data source and generate data models. |
| 12 | + |
| 13 | +## Create an account |
| 14 | + |
| 15 | +To continue with this guide, you'll need to have a Cube Cloud account. If you |
| 16 | +don't have one yet, [click here to sign up][cube-cloud-signup] for free. |
| 17 | + |
| 18 | +## Create a deployment |
| 19 | + |
| 20 | +First, [sign in to your Cube Cloud account][cube-cloud-signin]. Then, |
| 21 | +click <Btn>Create Deployment</Btn>: |
| 22 | + |
| 23 | +<div style="text-align: center"> |
| 24 | + <img |
| 25 | + alt="Cube Cloud Landing Screen with no configured deployments" |
| 26 | + src="https://ucarecdn.com/f3ec1ae0-1d5d-4b5b-9859-9fc145b38e43/" |
| 27 | + style="border: none" |
| 28 | + width="80%" |
| 29 | + /> |
| 30 | +</div> |
| 31 | + |
| 32 | +Give the deployment a name, select the cloud provider and region of your choice, |
| 33 | +and click <Btn>Next</Btn>: |
| 34 | + |
| 35 | +<div style="text-align: center"> |
| 36 | + <img |
| 37 | + alt="Cube Cloud Create Deployment Screen" |
| 38 | + src="https://ucarecdn.com/2338323e-0db8-4224-8e7a-3b4daf9c60ec/" |
| 39 | + style="border: none" |
| 40 | + width="80%" |
| 41 | + /> |
| 42 | +</div> |
| 43 | + |
| 44 | +## Set up a Cube project |
| 45 | + |
| 46 | +Next, click <Btn>Create</Btn> to create a new project from scratch: |
| 47 | + |
| 48 | +<div style="text-align: center"> |
| 49 | + <img |
| 50 | + alt="Cube Cloud Upload Project Screen" |
| 51 | + src="https://ucarecdn.com/46b72b61-b650-4271-808d-55203f1c8d8b/" |
| 52 | + style="border: none" |
| 53 | + width="80%" |
| 54 | + /> |
| 55 | +</div> |
| 56 | + |
| 57 | +## Connect a data source |
| 58 | + |
| 59 | +The last step in creating a deployment is to connect your data source to Cube |
| 60 | +Cloud. First, select the data source from the grid: |
| 61 | + |
| 62 | +<div style="text-align: center"> |
| 63 | + <img |
| 64 | + alt="Cube Cloud Setup Database Screen" |
| 65 | + src="https://ucarecdn.com/1d656ba9-dd83-4ff4-a59e-8b5f97a9ddcc/" |
| 66 | + style="border: none" |
| 67 | + width="80%" |
| 68 | + /> |
| 69 | +</div> |
| 70 | + |
| 71 | +<InfoBox> |
| 72 | + |
| 73 | +Want to use a sample database instead? Select <Btn>PostgreSQL</Btn> and use the |
| 74 | +credentials below: |
| 75 | + |
| 76 | +<br /> |
| 77 | + |
| 78 | +| Field | Value | |
| 79 | +| -------- | ------------------ | |
| 80 | +| Host | `demo-db.cube.dev` | |
| 81 | +| Port | `5432` | |
| 82 | +| Database | `ecom` | |
| 83 | +| Username | `cube` | |
| 84 | +| Password | `12345` | |
| 85 | + |
| 86 | +</InfoBox> |
| 87 | + |
| 88 | +After selecting the data source, enter valid credentials for it and |
| 89 | +click <Btn>Apply</Btn>. Check the [Connecting to Databases][ref-conf-db] |
| 90 | +page for more details on specific data sources. |
| 91 | + |
| 92 | +<div style="text-align: center"> |
| 93 | + <img |
| 94 | + alt="Cube Cloud Setup Database Screen" |
| 95 | + src="https://ucarecdn.com/1ccdb149-bcf3-4426-9103-986f092939b7/" |
| 96 | + style="border: none" |
| 97 | + width="80%" |
| 98 | + /> |
| 99 | +</div> |
| 100 | + |
| 101 | +If you run into issues here, make sure to allow inbound connections from Cube |
| 102 | +Cloud IP addresses to your database. This means you need to enable these IPs in |
| 103 | +your firewall. Using the screenshot in the example above, if you are using AWS, |
| 104 | +this would mean adding new [rules][aws-docs-sec-group-rule] to your database's |
| 105 | +[security group][aws-docs-sec-group]: |
| 106 | + |
| 107 | +| Source | Protocol | Port range | |
| 108 | +| --------------- | -------- | ---------- | |
| 109 | +| `3.65.255.79` | `TCP` | `5432` | |
| 110 | +| `3.69.4.168` | `TCP` | `5432` | |
| 111 | +| `3.64.153.169` | `TCP` | `5432` | |
| 112 | +| `18.185.128.84` | `TCP` | `5432` | |
| 113 | + |
| 114 | +Now that the deployment is configured, we can move on to [generating data |
| 115 | +models][ref-getting-started-cloud-generate-models]. |
| 116 | + |
| 117 | +[aws-docs-sec-group]: |
| 118 | + https://docs.aws.amazon.com/vpc/latest/userguide/security-groups.html |
| 119 | +[aws-docs-sec-group-rule]: |
| 120 | + https://docs.aws.amazon.com/vpc/latest/userguide/security-group-rules.html |
| 121 | +[cube-cloud-signin]: https://cubecloud.dev/auth |
| 122 | +[cube-cloud-signup]: https://cubecloud.dev/auth/signup |
| 123 | +[ref-conf-db]: /config/databases |
| 124 | +[ref-getting-started-cloud-generate-models]: |
| 125 | + /getting-started/cloud/generate-models |
0 commit comments