All pages
Powered by GitBook
1 of 11

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Lucee + Nginx

This AMI image will create a running Lucee site for you. If you do not want a ColdBox site we will show you how to remove it and have your own site. The first step is to have an AWS account. If you do not have one go to this URL to learn how to create an [AWS account.]( https://aws.amazon.com/premiumsupport/knowledge-center/create-and-activate-aws-account/)

  • Choose the Lucee CFML Server (Ubuntu+Nginx+Tomcat) AWS AMI. Go to this URL and do a search for Ortus at the top of the screen https://aws.amazon.com/marketplace/ and look for "Ortus solutions, corp"

Ortus Solutions AMIs
  • Click the View purchase options to subscribe button

  • Click the accept terms button.

  • Configuration options for subscription. In this section you can choose to add options to your contract, if not, You can click on "Continue configuration" button.

  • You can configure your Ortus Soluction software version or region, if not, just click on "Continue to Launch" button.

  • In "Launch" section you can choose method to launch, for this case, We're going to use EC2 method.

  • On the "Name and tags" page. Let's add a tag. Click the add Tag. They should be Key=Name and Value=Ortus Lucee CFML engine 5.2.9.31 (Ubuntu Server 18.04 LTS) Resource type=Instances.

  • This will take you to the "Choose an Instance Type." The default instance and AWS free tier selected is t3.micro. Unless you need more resources keep it at this.

  • If You desire or You do not have Key pair, You can generate new ones in "Key pair (login)" section. SAVE IT IN A SECURE PLACE!

  • On the "Network settings" section under "Firewall (Security groups)". We need to make a couple of changes. First is to go to the source column and select My IP so that SSH and RDP will only be enabled for your IP address (VERY IMPORTANT). Next allow HTTP and HTTPS. You can edit VPC, Subnet and Public IP configuration.

  • On "Configure Storage" section. If you want to persist your files, then add a volume. If you do not need to persist the files, keep the defaults.

  • On "Summary" section you can review general information about your instance, cancel operation, launch instance and also, you can generate AWS CLI commands to deploy EC2 instance with desired configuration.

  • You are on the "Launch Status" page. Go to the bottom right and click the button labeled "View Instances."

  • Select your running instance. This will open some tabs at the bottom of the page. Select the "Description" tab. Look to the right on the description tab and look for "Public DNS (IPv4)." To the right of this text is the DNS name. Copy that name and paste it in a browser. It should look something like this ec2-{public_dns}.compute-1.amazonaws.com.

  • Paste that URL in a browser and you should see the default ColdBox site.

  • SSH to your instance with following command ssh -i "/path/to/your/private-key" ubuntu@ec2-{public\_dns}.compute-1.amazonaws.com

  • When you SSH to the instance the web root is /web/coldbox-site/wwwroot RUN cd COMMAND WITH SUDO OR su TO ROOT USER

Enjoy your servers!

Purchase options for Ortus Solutions AMI
Accept terms for Ortus Solutions AMI
AMI subcription options
Ortus Solution software configuration
Instance launch method
Instance name and tags
Instance type
Key pair creation for instance
Instance security group
Instance storage
Instance Summay
Instance launch status
Instance view page

Other Engines

Create an EC2 instances from an Ortus BoxLang engine (Ubuntu Server 24.04 LTS) AMI (Amazon Machine Image). We have created several based Ubuntu based images.

Images
Status

Lucee + Nginx

✅ (With security updates only)

CommandBox + Nginx

✅ (With security updates only)

Changelog

Version 2.0.1_5.4.6.9

  • Security update for Apache Tomcat Server CVE-2025-24813

Version 1.0.0_5.2.3.9

  • Initial Release

Managing your web site

This page will show you how to mange your site using CommandBox and how to move files back and forth from your your development environment where ever that may be.

Now that you have a site running in the cloud you will want to customize it. Remember that SSH pem file you downloaded. That is going to allow you to go on the server and edit files. If you are on a windows platform like me. Here are some tools I strongly suggest that you get locally.

  1. CommandBox. This tool will allow you to make files and remove them locally. If you so decide that you want to edit and add files directly on the EC2 instance this can be done using the default instance of CommandBox on the server. https://commandbox.ortusbooks.com/

  2. VSCode the editor of choice, and the reason I say that is because it has so many useful extensions. https://code.visualstudio.com/download

  3. WinSCP the default file manager tool for Windows.

If you are using the Windows Package Manager you can download all of these from there.

Here is a script to download them in powershell. Save the script as anything.ps1. Remember where you saved it. With PowerShell, you must make sure is not Restricted. We suggest using Bypass to bypass the policy to get things installed or AllSigned for quite a bit more security.

  • Run Get-ExecutionPolicy. If it returns Restricted, then run Set-ExecutionPolicy AllSigned or Set-ExecutionPolicy Bypass -Scope Process.

Go to the right corner of the dialog box below and copy this script and save it naming it whatever you like as long as the extension ends as *.ps1

If your scripts successfully installed you should see a new desktop icon for VSCode. If you open a shell ( cmd, powershell, git bash ) and type box you should see that Commandbox is installed.

Managing your web site

This page will show you how to mange your site using CommandBox and how to move files back and forth from your your development environment where ever that may be.

Now that you have a site running in the cloud you will want to customize it. Remember that SSH pem file you downloaded. That is going to allow you to go on the server and edit files. If you are on a windows, Mac or Linux platform, here are some tools I strongly suggest that you get locally. The instructions below are for Windows but all of these tools are available for all 3 platforms.

  1. CommandBox. This tool will allow you to make files and remove them locally. If you so decide that you want to edit and add files directly on the EC2 instance this can be done using the default instance of CommandBox on the server.

  2. VSCode the editor of choice, and the reason I say that is because it has so many useful extensions.

Connecting via VSCode

VSCode is one of the hottest new editors on the market. We will show you how to connect via VSCode using the VSCode Remote Development Extension.

You can install the by visiting the URL or opening VSCode and clicking the extension load button in the IDE and searching for "Remote Development."

Steps to connect to ec2.

How to customize sites

By default you are given 2 web sites. This page will show you how to display and edit those sites.

Default Sites

The sites you are given are http://website1.com and http://website2.com. You can display these in your Windows Host file at C:\Windows\System32\drivers\etc\hosts. To see the site you add the entries like this below.

Open a browser with those URLS and you will see your site with the default ColdBox frameworks. In order to set different site names you will want to edit website1.conf and website2.conf files open a shell and navigate to:

https://winscp.net/eng/index.php
Chocolatey
Get-ExecutionPolicy

WinSCP the default file manager tool for Windows. https://winscp.net/eng/index.php

If you are using the Windows Package Manager Chocolatey you can download all of these from there.

Here is a script to download them in Powershell. Save the script as anything.ps1. Remember where you saved it. With PowerShell, you must make sure Get-ExecutionPolicy is not Restricted. We suggest using Bypass to bypass the policy to get things installed or AllSigned for quite a bit more security.

  • Run Get-ExecutionPolicy. If it returns Restricted, then run Set-ExecutionPolicy AllSigned or Set-ExecutionPolicy Bypass -Scope Process.

Go to the right corner of the dialog box below and copy this script and save it naming it whatever you like as long as the extension ends as *.ps1

If your scripts successfully installed you should see a new desktop icon for VSCode. If you open a shell ( CMD, Powershell, git bash ) and type box you should see that CommandBox is installed.

https://commandbox.ortusbooks.com/
https://code.visualstudio.com/download
replace all website2.com entries except the directory.
  • Restart Nginx and restart the server. Open your new site.

3.229.122.138		website1.com
3.229.122.138		website2.com
/etc/nginx/sites-enabled# ls
website1.conf  website2.conf
cat website2.conf
#Install Chocolatey
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))

#Assign Packages to Install
$Packages = 'commandbox',`
            'vscode',`
            'winscp'

#Install Packages
ForEach ($PackageName in $Packages)
{choco install $PackageName -y}
PS> .\anything.ps1 (enter)
#Install Chocolatey
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))

#Assign Packages to Install
$Packages = 'commandbox',`
            'vscode',`
            'winscp'

#Install Packages
ForEach ($PackageName in $Packages)
{choco install $PackageName -y}
PS> .\anything.ps1 (enter)
###############################################################
# Example
###############################################################
server {
        ################### SERVER NAME AND PORT #####################
        listen 80;
    server_name website2.com;

        ################### LOGS #####################
        access_log /var/log/nginx/website2-access.log;
        error_log /var/log/nginx/website2-error.log warn;
        rewrite_log off;

        ################### LOCATION #####################
        root /var/www/website2;

        ################### CFML #####################
        # Mod_cfml (Lucee) specific: add a unique ID for this server block.
        # For more info, see http://www.modcfml.org/index.cfm/install/web-server-components/nginx-all-os/
        set $lucee_context "website2.com";

        set $application_port "8002";
        include lucee.conf;
}
Click in the green box in the bottom left corner of VSCode. This will open a select box already populated with different Remote Development choices. You want to select Remote-SSH: Open SSH Configuration File...
Remote-SSH: Open SSH Configuration File...
  • If you have not created a configuration file you will have this option. Remote-SSH: Add New SSH Host... Select that instead.

  • Your configuration file should look something like this after you fill it out.

  • Having done that it is time to connect to your ec2 instance. Let's click the green button in the lower left corner. The same one we used to open the configuration file. Let's select "Remote-SSH: Connect Current Window to Host..."

Remote-SSH: Connect Current Window to Host...
  • If all works you should have a VSCode screen that looks like the one below. If it does not work you can do what I did, that is to downgrade to VSCode 1.36.1. You can do that with Chocolatey.

Notice you are on the ec2 server. You can run CommandBox Commands from here.
VSCode Remote Development Extension
Remote Development Extension
Host ColdBoxDemo
    User ubuntu
    HostName 34.236.192.135
    IdentityFile ~/.ssh/my-pem-that-i-downloaded-when-creating-ec2.pem

Connecting via WinSCP

Connecting to your server with WinSCP or VSCode

This page will walk you through connecting to your new server using the popular free software program WinSCP. I have a script for you to download on step 11 "Managing your web site" page.

WinSCP let's get going

  • Run WinSCP

  • In the Login dialog, click on the “New Session” button

  • Then click the "Advanced..." button

  • From this dialog select the SSH Authentication browse button to the right of the input box.

  • You will be given a file explorer box. Then select your pem file that you downloaded when you created your ec2. The prompt with look like this click ok.

  • Click the ok button

  • You have connected

choco install vscode --version=1.36.1 -y

Connecting to your server

Connecting to your server with WinSCP or VSCode

This page will walk you through connecting to your new server using the popular free software program WinSCP. I have a script for you to download on step 11 "Managing your web site" page. We will also take a look at an exciting VSCode extension called Remote Development. It allows you to SSH directly to the EC2 instance and map the remote folder in your local VSCode IDE.

Connect via WinSCP
SSU Authentication
Convert PEM file to a PPK file
Final Connection Step

CommandBox + Nginx

This AMI will allow you to configure as many Lucee sites as you desire using CommandBox and Nginx as a front end LB.

This AMI image will create a running CommandBox Lucee site for you. If you do not want a ColdBox site we will show you how to remove it and have your own site. The first step is to have an AWS account. If you do not have one go to this URL to learn how to create an [AWS account.]( )

  • Choose the AWS AMI. Go to this URL and do a search for Ortus at the top of the screen

  • Click the continue to subscribe button

Changelog

Version 1.0.0_5.3.7.47

  • Initial Release

Click the accept terms button

  • Next go to this page and click launch new instance https://console.aws.amazon.com/marketplace/home?#/subscriptions

  • This will take you to the "Choose an Instance Type." The default instance and AWS free tier selected is t3.micro. Unless you need more resources keep it at this. Go to the bottom of the screen and select Next:Configure Instance Details.

  • Choose an Instance Type
    • You are on the "Configure Instance Details" page and keep the defaults. Go to bottom of the page and click "Next: Add Storage" button.

    Configure Instance Details
    • You are now on the "Add Storage" page. Keep the defaults and click the button at the bottom right "Next: Add Tags."

    Add Storage
    • You are now on the "Add Tags" page. Let's add a tag. Click the add Tag. They should be Key=Name and Value=Ortus Commandbox CFML engine - multisite (Ubuntu Server 18.04 LTS). Next go to the bottom of the page and click the button that says "Next: Configure Security Group."

    Add Tags
    • You are on the "Configure Security Group" page. We need to make a couple of changes before leaving this page. First is to go to the source column and select MyIP so that ssh will only be enabled for your IP address (VERY IMPORTANT).

    • Next click the "Add Rule" button and under the type column select http and leave port 80 selected. Go to the bottom right of the page and select and click the "Review and Launch" button.

    Configure Security Group
    • You are on the "Review Launch Instance" page. Review it and once you are okay click the "Launch" bottom on the bottom right of page.

    Review Launch Instance
    • This opens a module window that is prompting you to suggesting an existing key pair or create a new open. If you do not know what this means I suggest you create a new key pair and put it in a folder that you have access to. If all went well you will see a green colored headline that says "Your instances are now launching."

    Select Key Pair
    • You are on the "Launch Status" page. Go to the bottom right and click the button labeled "View Instances."

    Launch Status
    • Select your running instance. This will open some tabs at the bottom of the page. Select the "Description" tab. Look to the right on the description tab and look for "Public DNS (IPv4)." To the right of this text is the dns name. Copy that name and paste it in a browser. It should look something like this

    • ec2-{public_dns}.compute-1.amazonaws.com

    • Paste that URL in a browser and you should see the default ColdBox site.

    • ssh -i "/local-path-to/myfile.pem" ubuntu@ec2-{public_dns}.compute-1.amazonaws.com

    • When you CD to the instance the 2 web roots are at sudo su cd /var/www/website1 /var/www/website2

    Running Instance

    Enjoy your server!

    https://aws.amazon.com/premiumsupport/knowledge-center/create-and-activate-aws-account/
    https://aws.amazon.com/marketplace/