This series of lines will create the instance within the free tier allowances. description="Port used for UniFi mobile speed test" \ target-tags=unifi-server gcloud compute firewall-rules create "unifi-throughput" \ target-tags=unifi-server gcloud compute firewall-rules create "unifi-stun" \ description="Port for device and controller communication" \
target-tags=unifi-server gcloud compute firewall-rules create "unifi-inform" \ description="Ports used for HTTP and HTTPS on non-standard ports" \ This series of lines will create several firewall rules needed for the Unifi controller and add them to a tag named unifi-server that will also be assigned to the server instance gcloud compute firewall-rules create "unifi-http" \ gcloud compute addresses create unifi-external \ If you destroy the instance without creating a replacement, or power it off for more than 1 hour, you may be charged for the static IP until you delete it. To prevent the external IP from changing over time, the IP can be reserved and remains free as long as it is attached to a running VM instance. Other regions are available in the free tier as long as they are in the US, excluding us-east4 (Check for details here: ) gsutil mb -c regional -l us-central1 gs://some-unique-name Creating a static external IP Make sure to replace some-unique-name with a name of your choosing. Copy and paste the commands, replacing text as needed Creating a storage bucketĪ storage bucket will hold the backups in a separate location so we can destroy the controller and restore from a reasonably recent backup very quickly. A black box will appear in the lower portion of the page with the Cloud Shell interface. As a result, the commands below will use Debian 9Īfter logging into the console site, click the button in the upper right corner to Activate Cloud Shell.
Attached is a text file with all commands that should properly copy and paste and may be easier to make modifications for your specific bucket names, DNS names, and regions.įinal Note: As of, the Unifi software still requires an earlier version of MongoDB than what is bundled with Ubuntu 18.04, requiring either a different OS, or some manual workarounds as described here. Note: Due to Instructable formatting, sometimes copy/paste do not work as expected. For those who want to build it manually or understand the nuts and bolts behind the scenes, the steps after this walk through the configuration. If using this method with the script from Petri, no further steps are needed as everything else is automated on Debian. Note: Free Tier is only available in the following Regions: us-east1, us-west1, and us-central1 This eliminates misconfiguration errors due to missed steps or mistypes. Was your previous controller running in docker? The command that I gave you would have put the Unifi controller data on the local drive at ~/unifi (or used whatever controller data existed there before).Rather than clicking through the GUI step by step to create the instance, Google provides Google Cloud Shell to build from a command line. It sounds like you created a new (empty) volume and are already configuring the controller from scratch. I have a working network but I guess I will have to start from scratch because I didn't create a backup.
I had a controller set up before and after new install of Ubuntu 20.04 on the same machine I am trying to set up a new controller replacing the old.
And in the last step it starts setting up but only gets to about 40% and then says my username and password is incorrect. It starts up fine and I put in my credentials in set 2 of 6, no devices to setup and skipped step 5 to setup Wifi. Also created a volume named unifi and ran your command. I deleted the image and container in Portainer.