Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
B
blog
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nimrod
blog
Commits
69755fc0
Commit
69755fc0
authored
4 years ago
by
nimrod
Browse files
Options
Downloads
Patches
Plain Diff
Post on notify.shore.co.il.
parent
19093668
No related branches found
No related tags found
No related merge requests found
Pipeline
#1416
passed
4 years ago
Stage: test
Stage: deploy
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
content/spam-me-notifications.rst
+46
-0
46 additions, 0 deletions
content/spam-me-notifications.rst
with
46 additions
and
0 deletions
content/spam-me-notifications.rst
0 → 100644
+
46
−
0
View file @
69755fc0
Spam me - Update #2
===================
:date: 2021-05-10
:summary: Another update the spam ma page.
Previously `I wrote <../spam_me/>`_ about the `spam me page
<https://www.shore.co.il/spam>`_ and later an `update <../spam-me-update>`_ on
how things were going.
Things were stable and I didn't get any spam. But something bothered me. I would
only get notifications on my laptop and only when it was on. Notifications would
be lost if the laptop was offline. Also, `Patchbay <https://patchbay.pub/>`_ had
downtime a few months back and I didn't get notifications at all. Lastly, I'm
keen on self-hosting.
Nextcloud Notifier
------------------
Nextcloud has a notification mechanism that is used internally. I get
notifications on pending updates on my cellphone and laptop. Pushing
notifications over HTTP requires authentication, but using the ``occ`` CLI
doesn't require authentication.
I wrote a `simple web service
<https://git.shore.co.il/nimrod/nextcloud-notifier>`_ to post messages through
the Nextcloud notification mechanism. The service runs the ``occ`` command using
``docker exec`` so usage is anonymous. Notifications are received on both
cellphone and laptop and I'm content. Now you can `send me messages
<https://www.shore.co.il/spam>`_
and I'll always get it.
Future uses
-----------
Now that I have a notification service, I saw more uses than I originally
envisioned. I send notification on failed Cron jobs, for example:
.. code:: shell
backup || wget --spider https://notify.shore.co.il/send?message=Backup%20failed.
I have CI jobs that run on a schedule (rebuilding container images) so now I
have a `GitLab CI template
<https://git.shore.co.il/shore/ci-templates/-/blob/master/templates/notify.yml>`_
that sends me a message if the CI pipeline failed.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment