Skip to main content

Server Installation

For the admin who know what they need, and needs a fast way to get it, you can use this command to setup and install Knocknoc server very quickly.

Knocknoc server currently only supported on Debian 11 or 12, or Ubuntu 22.04

Note - you need a license to use Knocknoc server, the details can be found here.

Self-Hosted Servers

  1. Log into your Knocknoc Server via the command line and become the root user.
  2. Run this command below to start the installation process. The script will then configure apt, setup secure repository access, and install the Knocknoc server.
    curl -sSL https://packages.knocknoc.io/setup/setup_knocknoc.sh | bash
  3. Accept the License Agreement.
  4. The Knocknoc server will ask for the IP to listen on and the port. By default it will listen on 0.0.0.0:8756, please adjust as your firewall or reverse proxy layout requires.
  5. The install will then ask for TrustedForwarders, by default 127.0.0.1/32 is entered but if the server is behind a reverse proxy, the IP of the reverse proxy will need to be entered. TrustedForwarders are the machines permitted to send the ForwardFor header to Knocknoc.
  6. Lastly the install will generate an SSL certificate and key, where it will ask you for Organizational Details. Knocknoc only communicates over HTTPS, so this certificate is to get you started, and can be replaced later.
  7. Once the script is completed, it will print the knocknoc-admin password. If you missed the output of the script;
    cat /var/log/syslog |grep knocknoc-admin or journalctl -u knocknoc |grep knocknoc-admin
  8. You are now ready to log into your Knocknoc admin portal.
  9. Browse to https://YourKnocknoc.url/admin and login with the knocknoc-admin user, please change the password.
  10. Click on Settings and paste the license key from the license portal and hit save.
  11. At this point if you wish you can setup Admin Portal Authentication or proceed with Agent Installation.
  12. You may also want to put Knocknoc itself behind Haproxy. Follow the guide for that here.

Cloud Servers

Your cloud instance is ready to go out of the box, with the license installed. You can jump straight to Agent Installation.

Your knocknoc-admin password should be available in the licensing portal, please change it on first login.