Create and Configure VM instance in GCP
I guess there should be nothing need to be mentioned for account creation. So I skipped to create VM Instance.
Choose VM Instance from menu

2. Create Instance

3. Choose image and disk size

4. Set allow both HTTP and HTTPS connection

5. This step is not required, as you can control the VM via browser. (I have tested it too) As all my setup are in putty environment, it is recommended to follow. Download and Putty to your computer, run puttygen.exe First, Generate a key, you need to move you mouse over the blank area of puttygen to ensure randomness. Then, change the Key comment to anything easy to type for you, it will be your login name in GCP.
Change the putty gen saving key setting, as some application (e.g. WinSCP) does not recognize PPK version 3.


Copy the public key (start with ssh-rsa, end with the key comment you typed, it will be paste in GCP) Save private key, it will be loaded later in Putty.

Click on Management , security, disks, networking, sole tenancy in GCP page, paste the key, then create

6. Change the external IP as static


7. Edit Firewall Rule of the VM


These are the rules I'm using: Port 443 Egress and Ingress are for xray data output and input Since I'm using AdGuard as DNS server too, port 3000, 853 and 8443 are open for DOH too Port 80 Ingress is use for updating SSL cert using acem

8A. SSH to the VM using Putty (for those who performed Step 5) Host Name: the external IP you found in Step 6

Then head for SSH, Auth to locate the ppk file you saved in Step 5. You can click open to start connection immediately, or you can go back to Session, type a name in "Saved Sessions" and press save for future use.

The login name here is the one you typed in Key Comment for Step 5.

8B. You can also open SSH session in web browser

After creation completed, you can move on to setup in Debian 10
Setup X-Ray Server in Debian 12Last updated
Was this helpful?