Debian 10/Ubuntu 20.04
If you notice any mistakes that need to be corrected, please reach out on Discord!
Petio supports two ways of connecting to a Mongo Database instance, locally or remote. We recommend the locally hosted MongoDB option.
MongoDB Locally
Make sure to add the correct repository to apt depending on whether you're using Debian or Ubuntu.
Import the public key used by the package management system:
wget -qO - https://www.mongodb.org/static/pgp/server-4.4.asc | sudo apt-key add -
Create the /etc/apt/sources.list.d/mongodb-org-4.4.list file:
echo "deb http://repo.mongodb.org/apt/debian buster/mongodb-org/4.4 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/4.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list
Reload local package database:
Install the MongoDB packages:
sudo apt-get install -y mongodb-org
sudo systemctl start mongod
Verify that MongoDB has started successfully:
sudo systemctl status mongod
To make sure MongoDB starts after restart use:
MongoDB Locally - On A Different Host
By default, MongoDB doesn’t allow remote connections.
Locate your mongod.conf and edit it with your favorite editor. Include any local IP addresses you want to allow to connect to your MongoDB instance.
Restart the mongod service after making these changes
If there is a firewall, you might need to use iptables to allow access to MongoDB. Example below:
Any connections can connect to MongoDB on port 27017
Only certain IPs can connect to MongoDB on port 27017
MongoDB Remotely
Change the provider or region if you need to. It may take some time to create the cluster.
After the cluster is made, click on connect and select MongoDB Compass and follow the instructions on screen.
Installing Petio
Make a directory for Petio:
Download the latest version of Petio:
Extract Petio to the directory we just made:
Change ownership of the directory for Petio:
Create the petio service with systemd:
Once you've completed theses steps, you can navigate to http://<hostname>:7777 to start configuring Petio.