Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


    Cloudron Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    ntfy.sh : self-hostable notifications

    App Wishlist
    10
    31
    874
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • timconsidine
      timconsidine last edited by

      https://ntfy.sh

      ntfy (pronounce: notify) is a simple HTTP-based pub-sub notification service. It allows you to send notifications to your phone or desktop via scripts from any computer, entirely without signup, cost or setup. It's also open source if you want to run your own.

      Really simple notifications for scripts, server status etc.

      curl -d "Backup successful 😀" ntfy.sh/mytopic

      If self-hosted, obviously change the ntfy.sh to your own domain.

      fbartels timconsidine 2 Replies Last reply Reply Quote 16
      • fbartels
        fbartels App Dev @timconsidine last edited by

        Notify.sh is indeed quite a cool project and has also seen good growth over the last few months.

        Depending on the use case I prefer to rely on third parties for checks/notifications. What good is a chat or email notification if my mail or chat server are down as well 😄

        Slightly more complicated curl, but this posts a message into a telegram message:

        curl https://api.telegram.org/bot$telegramApi/sendMessage -d chat_id=$telegramChat -d text="Backup successful 😀"
        
        timconsidine robi 2 Replies Last reply Reply Quote 5
        • timconsidine
          timconsidine @fbartels last edited by

          @fbartels neat !
          thank you - didn't know Telegram had this 'direct post'

          robi 1 Reply Last reply Reply Quote 1
          • robi
            robi @timconsidine last edited by

            @timconsidine Yeah, if you install our Server Monitor App, it also has that feature to send alerts via TG, Discord, etc..

            Life of Advanced Technology

            fbartels 1 Reply Last reply Reply Quote 0
            • robi
              robi @fbartels last edited by

              @fbartels if you have multiple cloudrons you could have each monitor each other.

              alternatively you could reverse monitor a single one by having something elsewhere consume liveness messages/notifications so you know when they stop.

              Easier to just use one of the free monitoring services to check your services externally.

              Life of Advanced Technology

              1 Reply Last reply Reply Quote 2
              • fbartels
                fbartels App Dev @robi last edited by

                @robi said in ntfy.sh : self-hostable notifications:

                our Server Monitor App

                Which app is that exactly?

                @robi said in ntfy.sh : self-hostable notifications:

                each monitor each other.

                yeah, if you want to be serious about monitoring then it should run with a different provider and in a different region than the rest of your stack. Or even better pay someone else to host a geo distributed monitoring for you.

                For my own use case Uptime Kuma is quite sufficient and can also send notification via Telegram.

                robi 1 Reply Last reply Reply Quote 2
                • timconsidine
                  timconsidine @timconsidine last edited by

                  I have made a first bash at packaging ntfy.sh for cloudron.

                  Some issues remain but seems useable.
                  Will be testing further.

                  Available at https://git.cloudron.io/timconsidine/ntfy-for-cloudron

                  timconsidine girish L 3 Replies Last reply Reply Quote 7
                  • timconsidine
                    timconsidine @timconsidine last edited by timconsidine

                    Use case example :
                    To get a daily report on status of a VPS (non-cloudron), a bash script is run by cron :

                    #!/bin/bash
                    echo 'MyDocker' > /root/ntfy-msg.txt
                    date >> /root/ntfy-msg.txt
                    if [ -f /var/run/reboot-required ]; then
                     cat /var/run/reboot-required >> /root/ntfy-msg.txt
                    fi
                    df -h / >> /root/ntfy-msg.txt
                    docker container ls --format 'table {{.Status}}\t{{.Names}}' >> /root/ntfy-msg.txt
                    curl ntfy.sh/xxxxxxx -T /root/ntfy-msg.txt
                    

                    which gives this :

                    MyDocker
                    Mon May 9 08:33:43 UTC 2022
                    Filesystem Size Used Avail Use% Mounted on
                    /dev/sda2 473G 32G 418G 7% /
                    STATUS NAMES
                    Up 2 days audiobookshelf
                    Up 2 days penpot_penpot-postgres_1
                    Up 2 days penpot_penpot-redis_1
                    Up 2 days nitter
                    Up 2 days nitter-redis
                    Up 2 days (healthy) netdata
                    Up 2 days budibase_proxy-service_1
                    ..... etc,
                    
                    girish 1 Reply Last reply Reply Quote 4
                    • girish
                      girish Staff @timconsidine last edited by

                      @timconsidine you are on a roll, I will look into both your packages this week. Thanks!

                      1 Reply Last reply Reply Quote 1
                      • girish
                        girish Staff @timconsidine last edited by girish

                        @timconsidine do you think you can add a LICENSE file to both your repos? We just use MIT license for our other packages, but any open source license will do.

                        timconsidine ericdrgn 3 Replies Last reply Reply Quote 1
                        • robi
                          robi @fbartels last edited by

                          @fbartels said in ntfy.sh : self-hostable notifications:

                          Which app is that exactly?

                          https://docs.cloudron.io/apps/php-server-monitor/

                          Life of Advanced Technology

                          1 Reply Last reply Reply Quote 1
                          • timconsidine
                            timconsidine @girish last edited by

                            @girish yep sure thing, will do.

                            1 Reply Last reply Reply Quote 0
                            • L
                              LoudLemur @timconsidine last edited by

                              @timconsidine Thank you for your packaging efforts. You must be becoming better and better at it. I hope you become so good at it soon that it becomes a cinch for you to do most things!

                              timconsidine 1 Reply Last reply Reply Quote 1
                              • timconsidine
                                timconsidine @LoudLemur last edited by

                                @LoudLemur 👍 you're too kind. I'm an amateur, just doing the easy stuff, but learning. More productive than sudoku to ward off dementia 😄

                                1 Reply Last reply Reply Quote 1
                                • timconsidine
                                  timconsidine @girish last edited by timconsidine

                                  @girish added LICENCE
                                  I thought best to copy over the licences from the original author repo.
                                  Wouldn't want to say anything different and offend them.
                                  If that's not best approach, do say.

                                  1 Reply Last reply Reply Quote 3
                                  • T
                                    thetomester13 App Dev last edited by

                                    Came searching for ntfy.sh and was not disappointed! I've been keeping track of this project's progress with their updates on r/selfhosted and it looks like they just released the first version of the iOS app!

                                    Is this image being kept up to date with releases? I think the server.yml file can be adjusted to automatically grab the CLOUDRON_APP_ORIGIN env variable so the user doesn't have to update it after install. Would love to see this published since it seems like it's already pretty close to the finish line. Let me know if I can help with getting this across!

                                    timconsidine 2 Replies Last reply Reply Quote 1
                                    • timconsidine
                                      timconsidine @thetomester13 last edited by timconsidine

                                      @thetomester13 : I haven't kept it up to date, but I will do so in my repo.

                                      Good news on the iOS app - will check it out

                                      EDIT : Just checked my self-package repo and I see that it just runs apt install ntfy into the base container.
                                      So for fresh installs you get the latest deployed apt package.

                                      For updates of previously deployed instances, I am not sure. Will try and learn.

                                      1 Reply Last reply Reply Quote 2
                                      • timconsidine
                                        timconsidine @thetomester13 last edited by

                                        @thetomester13 good point on the base_url

                                        Feel free to do a proper packaging.
                                        Mine was a bit of a hack for my own purposes.

                                        Would be great to see a proper version in the App Store.
                                        It's so just darned useful.
                                        I get morning reports from a variety of servers and machines. and also enquiries to things like Hetzner Storage Box, Scaleway and Wasabi so I can monitor status in 5 mins over a coffee.

                                        1 Reply Last reply Reply Quote 7
                                        • ericdrgn
                                          ericdrgn last edited by

                                          Would be excited to see this in the cloudron store proper myself! Thanks for all the work on it @timconsidine, good enough for now 🙂

                                          1 Reply Last reply Reply Quote 4
                                          • ericdrgn
                                            ericdrgn last edited by

                                            For anyone wondering it makes a great notification backend (on Android at least as that was all I tested) in coordination with self hosted matrix/element. The Android app has an option to use it as the backend, it doesn't change anything functionally about notifications but it does keep from using FCM which is the best part imo.

                                            jdaviescoates 1 Reply Last reply Reply Quote 1
                                            • jdaviescoates
                                              jdaviescoates @ericdrgn last edited by

                                              @ericdrgn said in ntfy.sh : self-hostable notifications:

                                              it doesn't change anything functionally about notifications but it does keep from using FCM which is the best part imo.

                                              Firebase Cloud Messaging?

                                              I use Cloudron with Gandi & Hetzner

                                              ericdrgn 2 Replies Last reply Reply Quote 0
                                              • ericdrgn
                                                ericdrgn @girish last edited by

                                                @girish any chance you had a chance to take a look at this to get an official package of it going? Just checking in, know you all have a lot going on these days.

                                                1 Reply Last reply Reply Quote 1
                                                • ericdrgn
                                                  ericdrgn @jdaviescoates last edited by

                                                  This post is deleted!
                                                  1 Reply Last reply Reply Quote 0
                                                  • ericdrgn
                                                    ericdrgn @jdaviescoates last edited by

                                                    @jdaviescoates said in ntfy.sh : self-hostable notifications:

                                                    @ericdrgn said in ntfy.sh : self-hostable notifications:

                                                    it doesn't change anything functionally about notifications but it does keep from using FCM which is the best part imo.

                                                    Firebase Cloud Messaging?

                                                    yes

                                                    1 Reply Last reply Reply Quote 1
                                                    • R
                                                      random_eric last edited by

                                                      @timconsidine
                                                      I updated the default server settings to have something more sensible and cleaned up the dockerfile a little bit.

                                                      You can find the repo here:
                                                      https://git.eyen.ca/cloudron/nfty.sh

                                                      Let me know what you think.

                                                      The email should work, but I don't know how to trigger it. The logs always says 0 emails sent. So I don't know how to test that.

                                                      timconsidine 2 Replies Last reply Reply Quote 6
                                                      • timconsidine
                                                        timconsidine @random_eric last edited by

                                                        @random_eric wow great, thank you.
                                                        Will take a look

                                                        1 Reply Last reply Reply Quote 2
                                                        • timconsidine
                                                          timconsidine @random_eric last edited by

                                                          @random_eric good job, better than mine.
                                                          I wonder if it is now more ready to be in the Cloudron appstore ?

                                                          I never bother with emails, too many, prefer alerts or dashboard, so missing email functionality is a bonus not a hindrance 😄

                                                          jdaviescoates R 2 Replies Last reply Reply Quote 3
                                                          • jdaviescoates
                                                            jdaviescoates @timconsidine last edited by

                                                            @timconsidine said in ntfy.sh : self-hostable notifications:

                                                            I wonder if it is now more ready to be in the Cloudron appstore ?

                                                            @girish said in ntfy.sh : self-hostable notifications:

                                                            @timconsidine you are on a roll, I will look into both your packages this week. Thanks!

                                                            Did you ever manage to take a look @girish

                                                            ntfy.sh would be neat to have in the app store! 🙂

                                                            I use Cloudron with Gandi & Hetzner

                                                            1 Reply Last reply Reply Quote 1
                                                            • R
                                                              random_eric @timconsidine last edited by

                                                              @timconsidine
                                                              I haven't been on the forums in a little while.
                                                              Is the appstore ready?

                                                              J 1 Reply Last reply Reply Quote 0
                                                              • J
                                                                jayonrails translator @random_eric last edited by

                                                                It is not on the official Cloduron App Store, but it might be possible to install it manually.

                                                                Pretty sure @random_eric can tell you more about it.

                                                                timconsidine 1 Reply Last reply Reply Quote 0
                                                                • timconsidine
                                                                  timconsidine @jayonrails last edited by

                                                                  @jayonrails

                                                                  You can find the repo here:
                                                                  https://git.eyen.ca/cloudron/nfty.sh

                                                                  1 Reply Last reply Reply Quote 3
                                                                  • First post
                                                                    Last post
                                                                  Powered by NodeBB