Week3 - Selesfia/ComputerNetwork GitHub Wiki

How to Add OpenAI Extension on Google Doc

  1. Go to this Google Docs Web and open a blank document
  2. Go to Extension -> Add-ons -> Get add-ons

  1. Search ChatGPT on the search bar and install GPT for Google Sheets and Docs

  1. After installing set your API Keys. You can get your API Key here. Click "Create new secret key" and name your API Key
  2. Back to Goole Docs website, go to Extension -> GPT for Sheets and Docs -> Set API Key -> and copy paste the API Key that you just created -> save

PS: It's only available for OpenAI Platform Paid Account, not for free trial account.

Create New Project on Google Cloud

  1. Click on "My project" and then click "new project"

  1. Give a name to your new project and set the location to "No Organization" for personal use after that just click "create"

  1. After creating the new project, change your current workspace to the project that you just created

Create new VM on Google Cloud

  1. Navigate to Compute Engine -> VM instances. If this is your first time using Compute Engine, click Enable to activate the Compute Engine API

  1. Click Create Instance
  2. Give your instance a name and choose the region and zone where you want to run your VM (in my case it's "myvm1", "asia-east1 (Taiwan)", "asia-east1-a")

  1. Choose the series of your machine

  1. choose your machine type and availability policies

  1. Choose the operating system. Click Change to select from options like Debian, Ubuntu, or Windows

  1. Once all the configurations are done click create

PS: Check Allow HTTP traffic and Allow HTTPS traffic if you want to host a web server

How to Connect Your Virtual Machine

SSH

  1. Navigate to VM Instance and click on "SSH". It will ask you to authorize

Result:

Cloud Shell

  1. Search for "Cloud Shell Editor" on search bar and install it
  2. Click "Open Terminal" and input the following command "gcloud compute ssh myvm1 --project=trim-mix-436602-e4 --zone=asia-east1-a". "myvm1" is your VM name, "trim-mix-436602-e4" is your project ID, and "asia-east1-a" is your zone where your VM is running
  3. The first time you connect, Cloud Shell may prompt you to create passphrase each time you try to login Result:

Cloud Cli

  1. Install the Google Cloud CLI here
  2. On the app that you just download input the same command "gcloud compute ssh myvm1 --project=trim-mix-436602-e4 --zone=asia-east1-a"

Result:

PS : Remember to delete the resources that you created if you don't use it anymore.

24/09/2024