Install Gotify Inside Docker Container in Linux

Install Gotify Inside Docker Container in Linux

Gotify is a notification server for sending and receiving messages. It supports REST API and WebSocket connection. Gotify provides a web UI for managing users, clients and applications.

This tutorial explains how to install Gotify inside a Docker container in the Linux. Commands have been tested on Ubuntu.

Prepare environment

Make sure you have installed Docker in your system. If you are using Ubuntu, installation instructions can be found in the post.

Install Gotify

  • Host network

Run the following command to create a container for Gotify that uses host network:

docker run -d --name=gotify --restart=always --network=host \
    -v /opt/gotify/data:/app/data \
    gotify/server
  • User-defined bridge network

User-defined bridge network can be used for listening on different port. By default, Gotify service is listening on port 80. It can be changed with -p option.

docker network create app-net
docker run -d --name=gotify --restart=always --network=app-net \
    -p 8080:80 \
    -v /opt/gotify/data:/app/data \
    gotify/server

Testing Gotify

Open a web browser and go to http://<IP_ADDRESS>, where <IP_ADDRESS> is the IP address of the system. Log in to the web UI with the default username (admin) and password (admin).

Gotify Inside Docker Container in Linux

Uninstall Gotify

To completely remove Gotify, remove its container:

docker rm --force gotify

Remove Gotify image:

docker rmi gotify/server

You can also remove Gotify data:

sudo rm -rf /opt/gotify

If a user-defined bridge network was created, you can delete it as follows:

docker network rm app-net

Leave a Comment

Cancel reply

Your email address will not be published.