Some more AWS related updates and fixes authored by Volker Hilsheimer's avatar Volker Hilsheimer
...@@ -3,8 +3,7 @@ Previous: [Continuously running unit tests in a local VM](tutorials/Run-Test-Con ...@@ -3,8 +3,7 @@ Previous: [Continuously running unit tests in a local VM](tutorials/Run-Test-Con
`minicoin` supports local VM providers such as VirtualBox or VMware Fusion, but `minicoin` supports local VM providers such as VirtualBox or VMware Fusion, but
through the relevant `vagrant` plugins it also can talk to machines running in through the relevant `vagrant` plugins it also can talk to machines running in
a public cloud. For AWS in particular, `minicoin` includes several features a public cloud. For AWS in particular, `minicoin` includes several features
that make it easy to set up a cloud machine that is easy to work with, secure, that make it easy to set up and manage a cloud instance.
and cost efficient.
This tutorial assumes that you have an AWS account. This tutorial assumes that you have an AWS account.
...@@ -39,15 +38,24 @@ run ...@@ -39,15 +38,24 @@ run
$ aws configure $ aws configure
``` ```
to authenticate. to authenticate. As part of the configuration you'll have to select a default region
for your account as well; some of the AMIs that are used by default or in this tutorial
are only available in the `eu-west-1` region, i.e. Ireland.
# Defining a cloud machine # Defining a cloud machine
Let's add a machine that runs in AWS to our `~/minicoin/minicoin.yml` file: Let's add a machine that runs in AWS:
```
$ minicoin machine add linux-aws
```
This will add a ready-made machine to the current user's minicoin configuration.
Alternatively, we can add such a machine to our `~/minicoin/minicoin.yml` file:
``` ```
machines: machines:
- name: ubuntu-aws - name: linux-aws
box: minicoin/linux-cloud box: minicoin/linux-cloud
provider: aws provider: aws
``` ```
...@@ -55,11 +63,11 @@ machines: ...@@ -55,11 +63,11 @@ machines:
This basic configuration makes sure that a `minicoin up linux-aws` always This basic configuration makes sure that a `minicoin up linux-aws` always
uses the `aws` provider to bring up a machine based on the `minicoin/linux-cloud` uses the `aws` provider to bring up a machine based on the `minicoin/linux-cloud`
vagrant box. That box uses the AMI for Ubuntu Server 20.04, and sets the AWS vagrant box. That box uses the AMI for Ubuntu Server 20.04, and sets the AWS
instance type to `t2.2xlarge`, which is a rather beefy (and thus also not instance type to `t3.2xlarge`, which is a rather beefy (and thus also not
super-cheap) machine with 8 vCPUs and 32 GB of RAM. super-cheap) machine with 8 vCPUs and 32 GB of RAM.
Before we can do anything with that machine, we need to install some software Unless we used the ready-made machine, we need to install some software
on it as part of the provisioning step: on it as part of the provisioning step before we can do anything with it:
``` ```
roles: roles:
...@@ -68,7 +76,7 @@ on it as part of the provisioning step: ...@@ -68,7 +76,7 @@ on it as part of the provisioning step:
- vnc-server - vnc-server
``` ```
This will install the the build tools and libraries required to build Qt; the This will install the build tools and libraries required to build Qt; the
default Linux desktop for Ubuntu; and a VNC server through which we can connect default Linux desktop for Ubuntu; and a VNC server through which we can connect
to the UI of the machine. to the UI of the machine.
...@@ -99,7 +107,7 @@ home partition on Linux (on a Windows machine, it would become drive D:, which ...@@ -99,7 +107,7 @@ home partition on Linux (on a Windows machine, it would become drive D:, which
Let's make sure that everything is set up correctly: Let's make sure that everything is set up correctly:
``` ```
$ minicoin validate ubuntu-aws $ minicoin validate linux-aws
``` ```
`minicoin` will now validate the AWS account, and if necessary create a `minicoin` will now validate the AWS account, and if necessary create a
...@@ -115,7 +123,7 @@ with any local VM: ...@@ -115,7 +123,7 @@ with any local VM:
``` ```
$ cd ~/qt/dev $ cd ~/qt/dev
$ minicoin run build ubuntu-aws $ minicoin run build --target Widgets linux-aws
``` ```
Note how the `run` command brings up the machine for us, and then waits for the Note how the `run` command brings up the machine for us, and then waits for the
... ...
......