Google Compute Engine provides public images preconfigured with SQL Server.
To create a SQL Server instance, specify the image family for the specific version of SQL Server that you need.
To create a SQL Server instance:
For images with SQL Server, you must select SQL Server images from the Applications tab.
-
In the GCP Console, go to the VM Instances page.
-
Click Create instance.
-
In the Boot disk section, click Change to begin configuring your boot disk.
-
On the Application images tab, choose a SQL Server image.
-
Click Select.
-
Click Create to create the instance.
After you create the instance, create a firewall rule to allow access to SQL Server on your instance.
The default SQL Server port is 1433.
-
In the Cloud Platform Console, go to the Firewall Rules page. In the GCP Console, go to the Firewall Rules page.
-
At the top of the page, click Create firewall rule to start creating a firewall rule.
-
Specify the details for this firewall rule.
-
In the Name field, specify a name for the firewall rule.
-
In the VPC network field, select the VPC network where your SQL Server instance is located.
-
For the Direction of traffic, select Ingress.
-
In Source filter field, select the range of IPs that you want to allow access on this port. For this example, you can select Allow from any source.
-
In the Allowed protocols and ports section, enter the port that SQL Server uses. For this example, specify tcp:1433; which is the default port.
-
Click Create to create this firewall rule and allow access to your SQL Server instance over port 1433.
If you need to add additional firewall rules to your instance, see the firewall rules documentation.