Prepare your server
One script turns a fresh Linux VPS into a host for your storefront. It installs Node.js, nginx and certbot, adds your domains with free Let's Encrypt certificates and runs your Nuxt, React or SvelteKit storefront as a system service.
How it works
The script installs itself as the orionplace command. Your storefront runs on the server as a service on a local port; nginx answers your domain over HTTPS and passes every request to it, and the storefront sends the API requests to your personal backend. Certificates renew automatically.
1 What you need
Before you start, check the server:
- A VPS with a public IP address and one of the supported Linux distributions (listed at the end of this page).
- Root access through
sudo. - At least 2 GB of memory to build the storefront; add a swap file on a smaller server.
- Ports 80 and 443 open, also in your hosting provider's firewall.
shop.example.com, and www.shop.example.com if you want it) to the server's IP address. Add the domain in your admin panel under Domains as well, so that your backend accepts it.2 Download and run the script
Connect to the server over SSH and run:
curl -fsSLo orionplace.sh https://orionmarket.place/downloads/orionplace.sh
sudo sh orionplace.sh setupIf the server has no curl, use wget:
wget -qO orionplace.sh https://orionmarket.place/downloads/orionplace.sh
sudo sh orionplace.sh setup3 What setup does
Setup detects the distribution and does the rest by itself:
- installs nginx, certbot and Node.js 24 LTS (the official build, checked against its checksum) unless Node.js 22.12 or newer is installed already;
- creates the service user
orionplaceand the folder/srv/orionplacefor storefronts; - connects nginx to the folder of managed sites;
- opens ports 80 and 443 in ufw or firewalld when one of them is active;
- schedules automatic certificate renewal;
- asks for an e-mail address for certificate notices from Let's Encrypt; press Enter to skip it.
4 A server that already runs nginx
Setup also works on a server that already runs nginx with other sites. It:
- uses the installed nginx and leaves its sites, settings and certificates as they are;
- adds only one file that loads the storefront sites: in the folder
nginx.confalready includes, or, whennginx.confincludes no folder, next to it with one include line innginx.conf(a backup ofnginx.confis kept); - stops before it changes anything when
nginx -talready reports errors or when another program, such as Apache, uses port 80 or 443; - restores your files when nginx rejects the result.
When you add a domain:
- the command refuses a name that another site already serves and names the file that serves it;
- a wildcard name of another site, such as
*.example.com, gives up only the added name, and the command asks first; - storefront sites also listen on every address your sites listen on;
- a certificate of another site is never reused: if one with the domain's name exists, the storefront gets its own certificate with
-orionplaceadded to the name; cert renewanddomain removetouch only the storefront certificates.
6 Next step
Install your storefront from npm with one command, for example sudo orionplace app install nuxt, or create the project yourself and run its install command. Both build the storefront, start it as a service and connect its domains with HTTPS.
7 Supported distributions
Tested on 64-bit x86 servers:
- Ubuntu22.04 · 24.04
- Debian12 · 13
- Rocky Linux9
- AlmaLinux8 · 10
- CentOS Stream9
- Oracle Linux9
- Amazon Linux2023
- Fedora42
- openSUSELeap 15.6 · Tumbleweed
- Arch Linuxlatest release
- Alpine Linux3.22
What was tested:
- On every distribution: preparing the server, adding a domain with a certificate, renewing the certificate and removing the domain.
- Debian 12 and Alpine: the Nuxt, React and Svelte storefronts installed as services.
- Debian 12, Rocky Linux 9, Arch Linux and Alpine: setup next to an existing nginx with other sites and certificates, which stayed unchanged.
- Debian 12: the three storefronts installed from npm with
orionplace app install.