anudeepND / anudeepND/whitelist

How to run python3 from within a docker container running on a Synology NAS?

Aperta
#235 6 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Python
Stelle
4.4k
Fork
289
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I have used Docker to install PiHole with its own IP-address on a Synology NAS. I have tried to install your whitelist through SSH but are facing problems. I have python3 but not inside the docker container. I have tried to find a solution on how to call it from within the container but with no success.

**SSH into docker**

Svettballe@Moln:~$ sudo docker ps -q
Password:
71772e7cb0d9
Svettballe@Moln:~$ sudo docker exec -it 71772e7cb0d9 bash
root@Pihole-MacvlanNetwork:/# git clone https://github.com/anudeepND/whitelist.git
Cloning into 'whitelist'...
remote: Enumerating objects: 1058, done.
remote: Counting objects: 100% (17/17), done.
remote: Compressing objects: 100% (17/17), done.
remote: Total 1058 (delta 7), reused 1 (delta 0), pack-reused 1041
Receiving objects: 100% (1058/1058), 661.32 KiB | 3.74 MiB/s, done.
Resolving deltas: 100% (570/570), done.
root@Pihole-MacvlanNetwork:/# cd whitelist/scripts
root@Pihole-MacvlanNetwork:/whitelist/scripts# ls
domains.sql referral.sh uninstall.py whitelist.py
root@Pihole-MacvlanNetwork:/whitelist/scripts# sudo python3 whitelist/scripts/whitelist.py
sudo: python3: command not found

**Python exists outside container**

Svettballe@Moln:/$ python3
Python 3.8.8 (default, Jun 2 2021, 08:52:25)
[GCC 7.5.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>

**How did you manage to run “sudo python3 whitelist/scripts/whitelist.py
“ when inside PiHole container in docker?**

Some step that is too obvious to mention for a programmer must be missing in the instructions, and I as a beginner cant figure it out.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.