FreeBSD
MongoDB
placeholder
Installing Petio
There is no package built for FreeBSD so the application will have to be built from source
Building from source
## Install dependencies
pkg install mongodb
pkg install npm
pkg install git (only if you want to use git to checkout the source)
npm install -g typescript
## Clone the repo and build the application
mkdir -p /usr/local/share/petio
cd /usr/local/share/petio
git clone -b dev https://github.com/petio-team/petio.git .
cd pkg/admin
npm install
npm run build
cd ../frontend
npm install
npm run build
cd ../api
npm install
npm run build
cd
mkdir -p /usr/local/petio
chown $petio_user:$petio_group /usr/local/petio
su -m $petio_user
setenv VIEWS_FOLDER /usr/local/share/petio/pkg/
setenv DATA_FOLDER /usr/local/petio
# Run the application
node /usr/local/share/petio/pkg/api/dist/main.js --host 0.0.0.0 --port 7777Create a Petio service
rc.d script to run petio. It checks whether mongod is enabled and running, warns if not, and forcefully starts it if not running.
Place this script in
/usr/local/etc/rc.d/petioGive it execute permissions:
chmod +x /usr/local/etc/rc.d/petioConfigure it in
/etc/rc.confsysrc petio_enable="YES"
optionally set user:
sysrc petio_user="petio"optionally set group:
sysrc petio_group="petio"optionally set data directory:
sysrc petio_data_dir="/usr/local/petio"
Once you've completed these steps, you can navigate to http://<hostname>:7777 to start configuring Petio.
Last updated