Skip to content

Commit 57cc507

Browse files
synced c4a instructions
1 parent efbe035 commit 57cc507

File tree

1 file changed

+57
-29
lines changed
  • content/learning-paths/servers-and-cloud-computing/node-js-gcp

1 file changed

+57
-29
lines changed

content/learning-paths/servers-and-cloud-computing/node-js-gcp/instance.md

Lines changed: 57 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -16,54 +16,82 @@ For support on GCP setup, see the Learning Path [Getting started with Google Clo
1616

1717
## Provision a Google Axion C4A Arm VM in Google Cloud Console
1818

19-
To create a virtual machine using the C4A instance type in Google Cloud Platform:
20-
21-
- Open [Google Cloud Console](https://console.cloud.google.com/).
22-
- In the left menu, select **Compute Engine**, then select **VM Instances**.
23-
- Select **Create Instance**.
24-
- In the **Machine configuration** section:
25-
- Enter a unique **Instance name**.
26-
- Choose your preferred **Region** and **Zone**.
19+
To create a virtual machine based on the C4A instance type:
20+
- Navigate to the [Google Cloud Console](https://console.cloud.google.com/).
21+
- Go to **Compute Engine > VM Instances** and select **Create Instance**.
22+
- Under **Machine configuration**:
23+
- Populate fields such as **Instance name**, **Region**, and **Zone**.
2724
- Set **Series** to `C4A`.
28-
- Select `c4a-standard-4` for the machine type.
25+
- Select `c4a-standard-4` for machine type.
2926

3027
![Create a Google Axion C4A Arm virtual machine in the Google Cloud Console with c4a-standard-4 selected alt-text#center](images/gcp-vm.png "Creating a Google Axion C4A Arm virtual machine in Google Cloud Console")
3128

32-
This configuration gives you four Arm vCPUs and 16 GB memory, optimized for Arm workloads.
3329

34-
## Select OS and finalize VM settings
30+
- Under **OS and Storage**, select **Change**, then choose an Arm64-based OS image. For this Learning Path, use **SUSE Linux Enterprise Server** or **Ubuntu**.
31+
- If using use **SUSE Linux Enterprise Server**. Select "Pay As You Go" for the license type.
32+
- If using **Ubuntu**, under the **Version** tab, please scroll down and select the aarch64 version of **Ubuntu 22.04 LTS**.
33+
- Once appropriately selected, please Click **Select**.
34+
- Under **Networking**, enable **Allow HTTP traffic**.
35+
- Click **Create** to launch the instance.
36+
- Once created, you should see a "SSH" option to the right in your list of VM instances. Click on this to launch a SSH shell into your VM instance:
3537

36-
After configuring the machine type, you'll need to select the operating system and finalize your VM settings. Follow the steps below to select an Arm64-based OS image, configure networking, and launch your instance. This ensures your VM is ready for Arm-native development and accessible for further setup.
38+
![Invoke a SSH session via your browser alt-text#center](images/gcp-ssh.png "Invoke a SSH session into your running VM instance")
3739

40+
- A window from your browser should come up and you should now see a shell into your VM instance:
3841

39-
- In the **OS and Storage** section, select **Change**:
40-
- Choose an Arm64-based OS image. For this Learning Path, select **SUSE Linux Enterprise Server**.
41-
- For **License type**, select **Pay as you go**.
42-
- Select **Select** to confirm your choices.
42+
![Terminal Shell in your VM instance alt-text#center](images/gcp-shell.png "Terminal shell in your VM instance")
4343

44-
- In the **Networking** section, enable **Allow HTTP traffic**.
44+
## Explore your instance
4545

46-
- Select **Review and create** to review your configuration.
46+
### Run uname
4747

48-
- Select **Create** to launch your VM instance.
48+
Use the [uname](https://en.wikipedia.org/wiki/Uname) utility to verify that you are using an Arm-based server. For example:
4949

50-
- After the VM is created, locate your instance in the **VM Instances** list.
51-
- Select the **SSH** button next to your instance to open a browser-based SSH shell.
50+
```console
51+
uname -m
52+
```
53+
will identify the host machine as `aarch64`.
5254

53-
{{% notice Note %}}
54-
If you don't see the **SSH** option, refresh the page or check that your VM is running. The SSH shell opens in a new browser window, giving you direct access to your Arm-based VM.
55-
{{% /notice %}}
55+
### Run hello world
5656

57+
Install the `gcc` compiler:
5758

58-
![Invoke a SSH session via your browser alt-text#center](images/gcp-ssh.png "Invoke a SSH session into your running VM instance")
59+
{{< tabpane code=true >}}
60+
{{< tab header="Ubuntu" language="bash">}}
61+
sudo apt update
62+
sudo apt install -y build-essential
63+
{{< /tab >}}
64+
{{< tab header="SUSE Linux" language="bash">}}
65+
sudo zypper refresh
66+
sudo zypper install -y gcc
67+
{{< /tab >}}
68+
{{< /tabpane >}}
5969

60-
A window from your browser should come up and you should now see a shell into your VM instance:
70+
Using a text editor of your choice, create a file named `hello.c` with the contents below:
6171

62-
![Terminal Shell in your VM instance alt-text#center](images/gcp-shell.png "Terminal shell in your VM instance")
72+
```C
73+
#include <stdio.h>
74+
int main(){
75+
printf("hello world\n");
76+
return 0;
77+
}
78+
```
79+
Build and run the application:
80+
81+
```console
82+
gcc hello.c -o hello
83+
./hello
84+
```
85+
86+
The output is shown below:
6387

88+
```output
89+
hello world
90+
```
6491

65-
## What you've accomplished
92+
## Automating Arm Based Infrastructure Deployment
6693

67-
You've successfully provisioned a Google Axion C4A Arm virtual machine running SUSE Linux Enterprise Server. You're now ready to install Node.js and deploy your workloads on Arm.
94+
Cloud infrastructure deployment is typically done via Infrastructure as code (IaC) automation tools. There are Cloud Service Provider specific tools like [Google Cloud Deployment Manager](https://cloud.google.com/deployment-manager/docs/).
6895

96+
There are also Cloud Service Provider agnostic tools like [Terraform](https://www.terraform.io/).There is a [deploying Arm VMs on (GCP) using Terraform learning path](/learning-paths/servers-and-cloud-computing/gcp) that should be reviewed next.
6997

0 commit comments

Comments
 (0)