deploy a Node.JS application

In this article, we’ll explain how to get started with the Node.JS application Strapi.

Activate a Node.JS hosting package and SSL

  1. For your domain name, order a Node.JS hosting package (currently only available for BETA testers)
  2. In Plesk, make sure Let’s Encrypt is active for the domain name

Configure your git repository

  1. Follow the git repository setup section on this page
  2. Write down your Github Repository URL

Add your git Repository

  1. Klik in het Plesk Dashboard op Install application en daarna op Deploy using Git
  2. Click on the Add Repository button
  3. As Repository URL, enter your Github Repository URL, for example: https://github.com/janjansen/strapi-plesk
  4. Click Create

Create a database

  1. In the Plesk Dashboard, click Databases
  2. Create a database and remember the database name, username and password
    Look here for help regarding creating a database.

configure the hosting package

  1. In Plesk, open the File Management page and open the httpdocs folder
  2. Rename .env.example to .env
  3. Open the file .env
  4. Now fill in all the details
  5. OST=0.0.0.0
    PORT=1337

    # `sqlite` or `mysql`
    DATABASE_CONNECTION_NAME=mysql

    DATABASE_HOST=localhost
    DATABASE_PORT=3306
    DATABASE_NAME=app_apidb
    DATABASE_USERNAME=app_apidbuser
    DATABASE_PASSWORD=XJX3yxt6gmx!due2twn

    # node -e "console.log(require('crypto').randomBytes(64).toString('base64'))"
    JWT_SECRET=
    ADMIN_JWT_SECRET

Starting your Node.JS application

  1. In Plesk, click Install application again and then Node.js
    1. Select as Document Root folder the document.root folder in the httpdocs folder
    2. As the Application Startup File , select the file server.js
  2. Click on Enable Node.JS button

  3. Strapi has now started

install dependencies

  1. In Plesk, click Node.JS and then NPM Install to install all dependencies

 

Need help from one of our hosting gurus?

Do you need an urgent answer to a question or help from our support? Our hosting specialists are more than happy to assist you!

Customer Support Team

Our customer service is open until 18:00 hour

Of neem een kijkje in onze 'stap-voor-stap' support handleidingen.

View support articles