The SPX source code is publicly available on [GitHub](https://github.com/TuomoKu/SPX-GC). Developers can clone the repository and run SPX directly using NodeJS.
> [!warning] The source code in the repository is always in a **work in progress** state and features may or may not work.
>
> For production use, we highly recommend our [commercial versions](https://spxgraphics.com/software/#compare) for updated features and software support.
### Prerequisites
- **Node.js** (v18 or later)
- **npm** (comes with Node.js)
- **Git** (for cloning the repository)
### Steps
1. Clone the repository:
```bash
git clone https://github.com/TuomoKu/SPX-GC.git .
```
2. Install dependencies:
```bash
npm i
```
3. Start the server:
```bash
node server.js
```
For development mode with hot reloading, use:
```bash
npm run dev
```
### Running with PM2
For production deployments from source code, consider using the [PM2](https://pm2.keymetrics.io/) process manager. PM2 keeps SPX running in the background, restarts it automatically on crashes, and provides monitoring tools.
```bash
npm start
```
You can also run several SPX instances simultaneously on different ports by using a PM2 `ecosystem.config.js` file. Each instance can have its own port and [[Documentation/Server/Configurations|configuration]].
> [!note] When running multiple instances, make sure each instance uses a unique `general.port` value in its [[Documentation/Server/Configurations|config.json]].