IN MY LAST POST, I talked about how the ‘ibmcloud’ CLI tool is useful for development but that I had encountered a number of clients where they had not been able to install it because of an enterprise-wide lockdown on their machines, which meant they could not install any software. To this end, I created a Public Image Template of a simple Linux server, which such users can use to create a new VM in the IBM Cloud, to which they can ssh and use the CLI tool, as well as Docker.
Well, what about other tools? A typical user needs a number of tools to be really productive, so how about creating a Public Image Template that does just that? So that’s what I’ve done.
This time, the virtual machine is based on Windows Server 2016 and has the following installed:
- The ibmcloud CLI
- Anaconda (a Python environment)
Rather than logging in with ssh, you can then Remote Desktop into the server, to use a graphical interface.
Using this Public Image Template is again, pretty simple; follow these steps:
- Log into your IBM Cloud account
- In the top left corner, click the ‘hamburger’ icon and select ‘Infrastructure’ from the drop-down menu (you can shortcut this step by just hitting control.bluemix.net)
- Click Devices -> Manage -> Images from the left-hand menu
- This will show your Image Templates. Where it says ‘Private Images’, select ‘Public Images’ from the drop-down
- Look for a template called Windows-Cloud-Developer-Server. Note, this page does not have a simple ‘search’ function, so it may be easier to order the templates by ‘Create Date’ (click on the heading) – the template was created on ‘2018-10-12’.
- Click on ‘Actions’ and select one of the ‘Order’ options. This will open an order form.
- Select the data centre where you would like the VM to reside. Normally, this would be the one closest to your physical location, or closest to your IBM Cloud deployment if they are different.
- Then pick a Flavour option. Remember that this is running Windows Server, so you may need a little more RAM. I tended to choose a Balanced instance with 2 vCPUs and 4GB RAM.
- Scroll to the bottom and click ‘Add to Order’
- This takes you to the ‘Check Out’ screen. Under the Advanced System Configuration settings, provide a hostname for your virtual server and a domain.
- Click the two check boxes to acknowledge T&Cs and License terms, then click Submit Order. At this point, your machine will start provisioning.
- Go back to your list of devices (click Devices -> Device List from the left-hand menu). You will see your machine is provisioning (denoted by a ‘clock face’ icon beside it.
- When the machine is provisioned, you will see a Public IP address (as well as a Private one) beside its name. Click on the name of the server.
- Log into the Windows server using Remote Desktop (or similar). The host is the public IP address.
- Provide the username and password for the user. The user is devuser and default password is devUSERPASSWORD! (case sensitive)
NOTE It is strongly recommended that you change the devuser password on your image, particularly if it persists for some time, since EVERY server created using this template will have this password as a default.
- You are now good to go! You can use the ibmcloud cli from a command prompt and if you click ‘Start’ you’ll find the other apps.
What does the image include?
The image includes the developer tools listed above. You can add more tools if you wish. Note that the image DOES NOT include any anti-virus software and the Windows Firewall is not activated.
- Think about how long your Virtual Machine might be needed for. Could you save money by provisioning a new machine each time you need it (note it can take up to 20 minutes) or by using Transient Virtual Servers?
- If you need to lock down access to the VM, consider using Security Groups and restricting access to a set IP address range, for example.
As before, you can find a full list of IBM Cloud CLI commands here