Skip to main content

Installation

Requirements

Octo is based on TypeScript, allowing you to use it as either a NodeJS project or a TypeScript project. Before you get started, here are a few things you need to ensure are installed and configured properly.

ProgramDescriptionVersion
NodeJSOcto requires a JavaScript based engine to run.
There are several help articles available online,
but we really love using nvm.
>= 18.x (Supported)
>= 20.x (Recommended)
aws-cliAssuming you want to build the infrastructure on AWS,
Octo requires access to AWS infrastructure.
We recommend following aws official docs, or our aws setup guide.
>= 2.x (Recommended)

Disclaimers

TypeScript vs NodeJS

The docs only provide syntax for TypeScript, but of course Octo projects can be written in pure NodeJS. If you decide to use just NodeJS, it is up to you to translate all instructions accordingly.

CJS vs MJS

Octo exclusively supports ESM modules, requiring "type": "module" in package.json. In this blog post, we explore using Octo with CJS modules. Please translate all instructions accordingly.

New Project

Create a new directory

mkdir octo-starter-project
cd octo-starter-project

Create new files

Octo is a monorepo by design. This is to promote consolidation of all infrastructure in one codebase. To create a new repository, please create all files in below tabs.

package.json
{
"name": "octo-starter-project",
"private": true,
"scripts": {
"build": "rimraf dist && tsc -p tsconfig.json",
"start": "node dist/main.js"
},
"type": "module",
"version": "0.0.1"
}

Install libraries

npm install @quadnix/octo @quadnix/octo-aws-cdk @quadnix/octo-event-listeners --save-prod
npm install @types/node rimraf ts-loader ts-node tsconfig-paths typescript --save-dev

Summary

In this article, we explored how to set up Octo on your local machine. Next, we will create a "hello world" project to introduce you to Octo.