Skip to content
This repository was archived by the owner on Jul 26, 2024. It is now read-only.

Commit

Permalink
4.0.0 (#317)
Browse files Browse the repository at this point in the history
* 4.0.0

* drop .sh

* chmod +x

* change pull locations

* push

* change folders

* cleanup extensions

* error with cname push

* backup purge redone

* back to the CORE!

* remove references to backup folder

* rename pihole container image variable

* rename pihole binary variables

* rename docker binary variables

* rename pihole dir variables

* data names

* remote and local

* DNSMASQ folders

* remove dnsmasq

* more variable renames

* fix config location

* fix import path

* validate gs folder fix

* remove references to LOCAL_FOLDR

* updater moving into place

* create update script

* "

* change context?

* remove git check

* add ( back

* Fix automation path

* replace standalone SQLite with FTL

* remote

* adjust docker folder locations

* fix remote location

* remove sqlite validation

* remove all references to cron

* config rewrite

* soruce config file

* remote file not dir

* hidden figures

* config file

* remove references to dropbear

* remove backup cleanup from most tasks

* remove gs folder validation

* remove ssh detection

* static set ssh

* id_rsa

* extra line

* echo lines

* retain previous config file

* isolinear

* ∞

* rearrange info

* remove bash path

* check replication status

* check timer instead

* dev mode against new repo location

* rewrite purge

* path

* add default file owner back

* simpler

* /usr/bin/bash

* fix ftl binary location

* whoami

* remote FTL

* don't delete from remote

* purge it

* remove path not name

* sudo tee

* tee off instead of echo out

* sudo sudo sudo

* sudo all the things

* Even more sudo

* how much more can you sudo

* change keyfile permissions

* remote/local

* all the sudo

* sudo in your rsync

* pull to tmp

* sudo copied

* silence tee

* New keyfile creation method

* send hash to the other side

* saving hashes

* directions are hard

* reverse hash for the other side

* remote ping test from config

* further randomize replication times

* rerandom

* fix bash call to update.sh

* Remove now-unused UI code

* remove legacy distro check code

* UI FILE PERMISSION spelling

* read -r

* GS_INTENT_VALIDATE

* remove intent validation from push

* cleanup tasks

* remove cname opt-out

* remove DNS options

* rename validation and set functions

* import_gs

* replace primary/local

* relocate file owner variables

* set variable for /tmp

* just set file permissions don't bother checking

* set file permissions

* remove extra message

* md5 variable renames

* replacing pri/sec variable names in smart sync

* .gsbackup replaced

* cleanup then

* removing compensation

* More primary and secondary references removed

* README update

* Update README.md

* new md5 variable

* multiple md5 hash logs

* gravity db listed twice

* md52 deletion at remote

* rename on sync

* move after send

* try try again

* this should work

* force it

* now for something completely different

* remove ;

* KISS

* KISS2

* fix hashing lookups

* set remote hash permissions

* vary info output

* remove unused functions

* new docs uploaded for publishing to wiki

* new system requirements

* words

* host

* rewrite install instructions

* rewrite install instructions

* rewrite all the thing

* massive variable renames

* building out dockerfile

* switch to photon

* change all if then style to single line

* cd || exit

* reformat math

* ${SSHPASSWORD} references removed

* OS_SSH_CMD set in variables

* cleanup function calls

* remove old root_check function

* cleaning up more variables

* more variable cleanup

* Line

* rewrite all of pihole detection

* echo_good

* >/dev/null 2>&1

* detecting local message

* sed?

* | sed 's/\s.*$//'

* fix sed

* no more whiches

* 2>/dev/null some more

* massive config rewrite for advanced workflow

* fix prompt

* output remote images

* echo again

* remote again

* cats?

* detect container locations

* fix space

* rewrite remote detection

* remote not local

* don't delete remote

* exec then rsync

* move lines

* enclose

* dont var

* daft

* quotes

* remove variable

* run you booger

* REMOTE

* remove echo_lines

* no config for more commands

* no config again

* shellcheck

* comment cleanup

* spell check is wonderful

* change docker container name output

* escape more quotes

* simpler command for remote side

* scape that?

* maybe less, i dunno

* try both lists again

* change spacing and line breaks

* streamline status icons for configuration

* retrieving remote settings

* error_validate

* disable task

* fix disable task

* detect_gs_peer

* task_purge doesn't use config

* remote message

* fallback

* " "

* comments

* add monitor mode

* Adds .sh script back as upgrader

* upgrader in old script

* reverse logic

* pretty upgrade script

* migration complete

* change template directory

* check for crontab hash

* user not host

* silence hash for crontab check

* warn

* warning

* reword config ending

* missing "

* os-release

* blue

* disable automation doesn't require config

* move stop

* signing off on 4.0
  • Loading branch information
vmstan authored Apr 11, 2022
1 parent ff32465 commit 41ecce4
Show file tree
Hide file tree
Showing 29 changed files with 2,662 additions and 3,298 deletions.
8 changes: 2 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
gravity-sync.log
gravity-sync.cron
gravity-sync.conf
gravity-sync.md5
logs/*
settings/gravity-sync.conf
dev
.vscode
.DS_Store
.nova
settings/*
logs/*
9 changes: 9 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM photon:4.0
LABEL maintainer="Michael Stanclift <https://github.com/vmstan>"

RUN tdnf update -y \
&& tdnf install -y curl git rsync openssh

RUN curl -sSL http://gravity.vmstan.com/beta | GS_DOCKER=1 && GS_DEV=4.0.0 bash

CMD gravity-sync version
27 changes: 12 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,37 +14,34 @@ What is better than a [Pi-hole](https://github.com/pi-hole/pi-hole) blocking tra

- [Seriously. Why two Pi-hole?](https://github.com/vmstan/gravity-sync/wiki/Frequent-Questions#why-do-i-need-more-than-one-pi-hole)

But if you have more than one Pi-hole in your network you'll want a simple way to keep the list configurations and local DNS settings identical between the two. That's where Gravity Sync comes in. With proper preparation, it should only take a few minutes to install. Ideally you setup Gravity Sync and forget about it -- and in the long term, it would be awesome if the Pi-hole team made this entire script unnecessary.
But if you have redundant Pi-hole in your network you'll want a simple way to keep the list configurations and local DNS settings identical between the two. That's where Gravity Sync comes in. Setup should only take a few minutes.

## Features

Gravity Sync replicates the Pi-hole Domain Database (`gravity.db`), which includes:
- Blocklist settings with status and comments.
Gravity Sync replicates the core of Pi-hole's resolver settings, which includes:

- Adlist settings with status and comments.
- Domain whitelist and blacklist along with status with comments.
- Custom RegEx whitelist and blacklists.
- Clients and groups along with any list assignments.

Gravity Sync can also (optionally) replicate the Local DNS Records and CNAMEs configuration files.
- Clients and groups, along with any list assignments.
- Local DNS Records.
- Local CNAME Records.

### Limitations

Gravity Sync will **not**:

- Overwrite device specific Pi-hole settings specific to the local network configuration.
- Change the Pi-hole admin/API passwords, nor does not leverage these at all.
- Modify the individual Pi-hole's upstream DNS resolvers.
- Sync DHCP settings or monitor device leases.
- Merge long term data, query logs, or statistics.

## Setup Steps

1. [Review System Requirements](https://github.com/vmstan/gravity-sync/wiki/System-Requirements)
2. [Prepare Your Pi-hole](https://github.com/vmstan/gravity-sync/wiki/Installing#primary-pi-hole)
3. [Install Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#secondary-pi-hole) (or [Upgrade](https://github.com/vmstan/gravity-sync/wiki/Updating))
4. [Configure Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#configuration)
5. [Execute Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#execution)
6. [Automate Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#automation)
7. [Profit](https://memory-alpha.fandom.com/wiki/Rules_of_Acquisition)
2. [Install Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing)
3. [Configure Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#configuration)
4. [Execute Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#execution)
5. [Automate Gravity Sync](https://github.com/vmstan/gravity-sync/wiki/Installing#automation)

## Disclaimer

Expand All @@ -58,4 +55,4 @@ Please refer to the [Wiki](https://github.com/vmstan/gravity-sync/wiki) for more

- [Frequently Asked Questions](https://github.com/vmstan/gravity-sync/wiki/Frequent-Questions)
- [Advanced Installation Options](https://github.com/vmstan/gravity-sync/wiki/Under-The-Covers)
- [Changelog](https://github.com/vmstan/gravity-sync/wiki/Changelog)
- [Changelog](https://github.com/vmstan/gravity-sync/wiki/Changelog)
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.7.0
4.0.0
5 changes: 0 additions & 5 deletions backup/BACKUP.md

This file was deleted.

Loading

0 comments on commit 41ecce4

Please sign in to comment.