Giter Site home page Giter Site logo

bash-scripts's Introduction

bash-scripts

This is a collection of bash scripts I've hacked together over time which may be useful enough that I'm sharing them on GitHub

I have a moderate amount of skill in bash. I am no expert, but I am no novice either. There may be better ways to execute the flow of logic I am trying to achieve in these scripts. If you have a suggestion, I would welcome a pull request. If you have an issue, you are welcome to create an Issue or reach out to me on IRC. I idle in #goose on Libera, and usually respond within a few hours of being highlighted.

Unless otherwise noted, all scripts in this repository are covered by the MIT liencse

These scripts will generally work by sourcing the "Config" options to a .env file with the same base file name, and kept in the same directory. So for example, if you want to use the captive-dns.bash script, you will need to place captive-dns.env in the same directory next to it. The config file names are dynamic to the script file name. So if you wanted to rename captive-dns.bash to force-dns.bash, then your config file would need to be force-dns.env in the same directory.

I will generally try and write in a -h or --help flag as well, that you can run scripts with to see what options they have.

Scripts here include:


captive-dns.bash
A script meant for the UniFi Dream Machine line, which can be used to force DNS to a specific DNS server. This can be useful to force devices which ignore the DNS server handed out by DHCP to use the DNS server of your choice, such as a Google Home. The script will run every minute to ensure your configured DNS server is actually working, and switch to backup option(s) if it is not.
Link to Script: captive-dns.bash
Link to .env File: captive-dns.env

linode-dynamic-dns.bash
A script meant to update a dynamic IP address via Linode's DNS manager.
Link to Script: linode-dynamic-dns.bash
Link to .env File: linode-dynamic-dns.env

sonarr-group-notifications.bash
A script meant to group Sonarr import notifications if a bunch of the same series item are in the queue. This is meant to send one big notification of all items for that series, rather than getting spammed with a thousand individual notifications. This script is currently undergoing a total rewrite, and will be available again...soon™

sonarr-update-tba.bash
A script meant to find media files with the name "TBA" in your library, and issue the necessary commands to Sonarr to attempt to rename those files. It will also attempt to find and refresh metadata for "TBA" items in your Plex library, if configured to do so.
Link to Script: sonarr-update-tba.bash
Link to .env File: sonarr-update-tba.env

update-plex-in-docker.bash
The Plex Media Server docker container installs the latest version within the container, each time it is started. Therefore, we cannot install PMS updates simply by waiting for a new version of the container. Rather, we must restart the container when an update is available. This script automates that process, with some sanity checks to make sure no one is watching anything first.
Link to Script: update-plex-in-docker.bash
Link to .env File: update-plex-in-docker.env

Todo

Done ✓

  • Update captive-dns.bash to new standard
  • Updated Telegram sending function to support super groups, silent notifications
  • Update Docker container IP address detection to deal with containers with multiple networking types
  • Update linode-dynamic-dns.bash to new standard
  • Update update-plex-in-docker.bash to offer to use ChuckPA's database repair/optimization tool between updates

bash-scripts's People

Contributors

goose-ws avatar ndoty avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.