Skip to content

Commit ea86a08

Browse files
authored
Add a Compute Resource overview page (#25)
* Add a Compute Resource overview page This made the whole thing a bit less confusing hopefully * Rename section *Compute Resource* to *Resource*
1 parent ec9b9d2 commit ea86a08

File tree

5 files changed

+77
-22
lines changed

5 files changed

+77
-22
lines changed

docs/.vitepress/config.mts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,9 +203,10 @@ export default defineConfig({
203203
]
204204
},
205205
{
206-
text: 'Compute Resources',
206+
text: 'Compute',
207207
collapsed: false,
208208
items: [
209+
{text: 'Introduction', link: '/devhub/compute-resources/'},
209210
{ text: 'Standard Instances', link: '/devhub/compute-resources/standard-instances/' },
210211
{ text: 'GPU Instances', link: '/devhub/compute-resources/gpu-instances/' },
211212
{

docs/devhub/compute-resources/functions/getting-started.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,18 @@
11
# Getting started with functions
22

3-
This tutorial will guide you through the steps of building a Python microVM to run on the aleph cloud network.
3+
This tutorial will guide you through the steps of building a Python microVM to run on the Aleph Cloud network.
44
We will build a simple HTTP server and add features as we go.
55

66
> ℹ This tutorial uses the aleph cloud command line interface.
77
8+
## Prerequisites
9+
10+
Before you begin this tutorial, ensure that you have the following:
11+
12+
* A computer with Python and the [aleph-client](https://github.com/aleph-im/aleph-client/) utility installed
13+
* An Ethereum account with at least 2000 ALEPH token
14+
* Working knowledge of Python
15+
816
## Requirements
917

1018
We expect you to know a little Python and have some experience with Python web frameworks such as

docs/devhub/compute-resources/functions/index.md

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
11
# Computing on Aleph Cloud
22

3-
Aleph Cloud offers a decentralized computing framework that allows users to run
4-
applications on the network.
3+
Aleph.cloud programs are applications running on the aleph.cloud network.
4+
Each program defines the application to be executed, data to use, computing requirements
5+
(number of CPUs, amount of RAM) and many more parameters.
56

6-
Two execution models are available:
7+
Functions follow a serverless approach to easily deploy and maintain applications. They
8+
offer [Function-as-a-service](https://en.wikipedia.org/wiki/Function_as_a_service) functionality.
79

8-
- [Functions](/devhub/compute-resources/functions/getting-started) follow a serverless
9-
approach to easily deploy and maintain applications.
10-
- [Instances](/devhub/compute-resources/standard-instances/) are designed to
11-
provide a persistent environment for users to interact with directly.
10+
Each function is instantiated as a __virtual machine__ running on a Compute Resource Node (CRN).
11+
Virtual machines are emulated computer systems with dedicated resources that run isolated from each other.
12+
Aleph.cloud Virtual Machines (VMs) are based on Linux.
1213

13-
In both cases, user workloads are executed inside virtual machines (VMs)
14-
isolated from each other.
1514

1615
## Overview of VMs
1716

@@ -105,7 +104,7 @@ cd ./src/
105104
uvicorn main:app --reload
106105
```
107106

108-
### Step 2: Run a program in a persistent manner
107+
### Step 2: Run a program in persistent mode
109108

110109
To run the program in a persistent manner on the aleph.cloud network, use:
111110

@@ -118,7 +117,3 @@ You can stop the execution of the program using:
118117
```shell
119118
aleph unpersist $MESSAGE_ID
120119
```
121-
122-
### Find your program
123-
124-
TODO: Locate the CRN where your program is running.
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# Computing on Aleph Cloud
2+
3+
Aleph Cloud offers a decentralized computing framework that allows users to run
4+
applications on the network.
5+
6+
Two execution models are available:
7+
8+
- [Functions](/devhub/compute-resources/functions/) follow a serverless
9+
approach to easily deploy and maintain applications. They offer [Function-as-a-service](https://en.wikipedia.org/wiki/Function_as_a_service) functionality
10+
- [Instances](/devhub/compute-resources/standard-instances/) are designed to
11+
provide a persistent environment for users to interact with directly. They offer full Virtual Machine running under qemu.
12+
13+
Functions can be executed in parallel on multiple Compute Resource Nodes while there will only one running instance on the network.
14+
15+
In both cases, user workloads are executed inside virtual machines (VMs)
16+
isolated from each other.
17+
18+
## Overview of VMs
19+
20+
There are several types of VMs available on the network:
21+
22+
- [On-demand VM](#on-demand-execution)
23+
- [Persistent VM](#persistent-execution)
24+
25+
An [On-demand VM](#on-demand-execution) is created on a [Compute Resource Node](/nodes/compute/introduction/)
26+
(CRN) and is destroyed once the program has finished executing. This is great
27+
for programs that are responding to user requests or API calls (using ASGI) and can shutdown
28+
after processing the event. They are also cheaper to run as they only require
29+
one tenth of the $ALEPH tokens to hold, compared to a [Persistent VM](#persistent-execution).
30+
31+
A [Persistent VM](#persistent-execution) can be used to run programs that cannot afford to stop or need
32+
to handle incoming connections such as polling data from a websocket or AMQP API.
33+
34+
Instances are similar to Persistent VMs, but are specifically designed to run with
35+
a SSH key supplied by the user. This allows the user to connect to the VM and
36+
interact with it directly. They do not rely on code execution, but rather on
37+
the user's ability to connect to the VM and run commands on it.
38+
They cost as much as Persistent VMs.
39+
40+
# Instances
41+
42+
See [Instances](/compute-resources/standard-instances/index.md)
43+
44+
In additions you can request usage of a [GPU](/compute-resources/gpu-instances/index.md) or use [Confidential instances](/compute-resources/confidential-instances/01-confidential-instance-introduction.md)

docs/devhub/compute-resources/standard-instances/index.md

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,28 @@
22

33
This section outlines the process of starting a standard (CPU-only) instance on the Aleph Cloud network.
44

5+
6+
## via the Web
7+
8+
You can create, manage your instances viathe [Aleph Cloud Console](https://app.aleph.cloud).
9+
10+
## via the CLI
11+
512
The [aleph-client](https://github.com/aleph-im/aleph-client/) command-line tool is required.<br>
613
See [CLI Reference](/devhub/sdks-and-tools/aleph-cli/) or use `--help` for a quick overview of a specific command.
714

8-
## Setup
9-
10-
### Create a Standard Instance
15+
### Create a Standard Instance via the CLI
1116

12-
To create a standard instance, use the CLI or the [Aleph Cloud Console](https://app.aleph.cloud).
17+
Prerequisite: A ssh key so you can log onto into your VM, you can create one using the `ssh-keygen` command.
18+
To create a standard instance, use:
1319

1420
```shell
1521
aleph instance create
1622
```
17-
<br/><br/>
1823

19-
Your VM is now ready to use.
24+
An instance will guide you and ask you question on how you want to configure your VM: base system, disk size, etc...
25+
26+
Once the process is complete, your VM should be ready to use in a few minutes.
2027

2128
### Retrieve VM Logs
2229

0 commit comments

Comments
 (0)