-
Notifications
You must be signed in to change notification settings - Fork 100
Deploy Lightwave on GCE
Pre-requisites
- Please follow GCE's gcloud SDK install guide @ https://cloud.google.com/sdk/downloads so that you can manipulate your GCE VM instances with gcloud CLIs including establishing SSH connections to your GCE VM instances.
-
For lightwave DNS we need open protocols and port: udp:53, tcp:53
-
For lightwave ldap we need open protocols and port: udp:389 tcp:389 udp:636 tcp:636
-
For lightwave sts we need open protocols and port: tcp:443
-
For lightwave rpc and others we need open protocols and port: tcp:88 tcp:88 tcp:2012 tcp:2014 tcp:2020
Log in to your GCE account and create a project, i.e. named 'lightwave domain'. Go to https://vmware.github.io/photon/ to download PhotonOS image built for GCE and upload it your GCE project. This includes two steps:
- Upload image to Google Storage: go to 'Storage' to create a bucket under your project and upload your image there.
- Create customer image: go to 'images' and select 'create an image', where you choose 'cloud storage file' and pick the PhotonOs image you upload previously.
Browse to 'Compute Engine' -> 'VM instances' -> 'CREATE INSTANCE', from where we will set up lightwave domain with first domain controller, i.e. 'lightwave-dc01' and subsequent domain replica, i.e. 'lightwave-dc02' etc.
You should be able to choose '1G' memory, and make sure you choose 'customer image' and browse to your project and choose the PhotonOS image you uploaded in step 2. Click to enable 'http/https'.
Set the following in the startup script section
hostname $(curl --silent http://metadata.google.internal/computeMetadata/v1/instance/attributes/hostname" -H "Metadata-Flavor: Google")
Next, click on the VM instance launched in step 3 and click 'edit' and browse to "Custom metadata" and add two properties:
hostname = FQDN of your host, for instance, "lw-dc01.photon.local'
In this section, we will login to our newly formed instance and configure the hostname correctly
-
ssh into the newly formed instance
-
Update the /etc/hosts file with the following entry
(use ifconfig to determine your instance's ip address)
For example
10.138.0.6 lw-dc01.lightwave.local lw-dc01
- Verify that the instance records the short name and fqdn correctly
Run the following commands
$hostname
lw-dc01
$hostname -f
lw-dc01.photon.local
Open '/etc/resolve.conf' and add "nameserver 1st_lightwave_instance_ip" for instance "nameserver 10.138.0.6" at the top line. Note: the first lightwave instance will also need this entry to point to itself in order for lightwave DNS work correctly.
Make sure you run
systemctl restart systemd-networkd; systemctl restart systems-resolved
to allow network/hostname configuration take effect on your VM instance.
Connect to your VM instance, and run 'sudo su' to be root.
sudo su
tdnf makecache
tdnf install -y commons-daemon-1.0.15-8.ph1 openjre-1.8.0.112 apache-tomcat-8.5.8 (Require a specific version of 3rd dependency will be fixed in future lightwave server release)
tdnf install -y vmware-lightwave-server-1.2.0
* /opt/vmware/bin/configure-lightwave-server --domain <domain name> --password <password>
Repeat Step 3, 4, 5 and 6 where we install and configure another instance.
* /opt/vmware/bin/configure-lightwave-server --domain <domain name> --password <password> --server <1st_lightwave_server_fqdn>
You can choose to bring up more lightwave domain controllers in the same lightwave domain by repeating step 8 and 9 above.
Follow the photon step 1 of Photon with photon to configure the firewall