diff --git a/.drone.yml b/.drone.yml index fd961dd..53f8b02 100644 --- a/.drone.yml +++ b/.drone.yml @@ -35,6 +35,10 @@ steps: - cd /mnt/md0/infra/pi-hole - git pull - make restart + - name: cleanup + commands: + - cd /mnt/md0/infra/pi-hole + - make cleanup trigger: branch: diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..73069d4 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,10 @@ +root = true + +[*] +charset = utf-8 +end_of_line = lf +indent_style = space +indent_size = 2 +trim_trailing_whitespace = true +insert_final_newline = true +max_line_length = 100 diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..b195b12 --- /dev/null +++ b/LICENSE @@ -0,0 +1,19 @@ +MIT License Copyright (c) 2021 fedy95 + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice (including the next +paragraph) shall be included in all copies or substantial portions of the +Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS +OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF +OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/Makefile b/Makefile index 518ac6c..e616097 100644 --- a/Makefile +++ b/Makefile @@ -12,7 +12,11 @@ lint-yaml: $(LINT-YAML-CMD) docker-compose.yml restart: - docker-compose -f docker-compose.yml down - docker-compose -f docker-compose.yml up -d + docker-compose -f docker-compose.yml pull + docker-compose -f docker-compose.yml restart + +cleanup: + docker system prune --all --force + docker system prune --volumes --force .DEFAULT_GOAL := lint diff --git a/README.md b/README.md index ade5a33..e24f426 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,6 @@ -### pi-hole -[![Build Status](https://drone.fedy95.com/api/badges/infra/pi-hole/status.svg)](https://drone.fedy95.com/infra/pi-hole) +### pi-hole [![Build Status](https://drone.fedy95.com/api/badges/infra/pi-hole/status.svg)](https://drone.fedy95.com/infra/pi-hole) + +--- ### services - [docker-pi-hole](https://github.com/pi-hole/docker-pi-hole) @@ -8,10 +9,10 @@ ### run ```shell script # for check a port 53 -netstat -ntlp | grep LISTEN +netstat -ntlp | grep LISTEN # resolv.conf -ll /etc/resolv.conf +ll /etc/resolv.conf lrwxrwxrwx 1 root root 39 Apr 23 07:33 /etc/resolv.conf -> ../run/systemd/resolve/stub-resolv.conf sudo sed -r -i.orig 's/#?DNSStubListener=yes/DNSStubListener=no/g' /etc/systemd/resolved.conf @@ -62,4 +63,4 @@ nslookup flurry.com : flurry.com Addresses: :: 0.0.0.0 -``` \ No newline at end of file +```