Open Jacktofine opened 7 years ago
Hi;
As far as I know, you don't need to change anything in the codes to make it work. So make sure you're running the code in the proper directory. First cd system
then python WebApp.py
. It should work. :-)
Cheers, Vahid
your problem is probably because you did not mount the local directory (in your server/vm) properly when you did docker run. The example provided is missing the local/container directory (well at least for me those were not identical). Vahid is right you don't need to change anything in the code for this to run fine.
@mathieuduperre i want to change code , how can i do this inside docker.
your question is not clear. here's what i can tell you:
after you start your docker, assuming you are not "in" your docker, run: docker ps you will get a list of running docker. docker attach (insert_docker_name_here) you will end in your container. from there, cd /root/home_surveillance (exact directory may vary)
that's the root of your project. most of the code you probably want to change will be under that directory, root/home_surveillance/system/
good luck!
Thanks very much for your reply. Actually my question is .. i want to change Web.py file inside home_survelliance/system directory so how can i change code inside pre build docker image.
Inside root directory home_surveillance/system/ is not available.
root@f3c210a91272:~# pwd /root root@f3c210a91272:~# ls flask openface torch root@f3c210a91272:~#
if you used the same mechanism as recommended, you are mapping an external dir in your container. so you should be able to modify the file from within the container or outside the container. I think it should keep both changes (i may be wrong, changes in the container may not be kept, unsure). I usually use the git repo to manage such changes.
Thanks very much :-)
On Fri, Apr 21, 2017 at 8:52 PM, mathieuduperre notifications@github.com wrote:
if you used the same mechanism as recommended, you are mapping an external dir in your container. so you should be able to modify the file from within the container or outside the container. I think it should keep both changes (i may be wrong, changes in the container may not be kept, unsure). I usually use the git repo to manage such changes.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/BrandonJoffe/home_surveillance/issues/19#issuecomment-296220995, or mute the thread https://github.com/notifications/unsubscribe-auth/AIKxMeE0aSl9Obqz7msHPnGxfPsRGgVeks5ryMmmgaJpZM4MIpFd .
I have solved this question by construct a new images by Dockerfile.Thanks for everyone's help !
error :( https://ibb.co/caBBZT
@yemrekula0748 Have you followed the installation process? Pull the docker image and run it. If you don't want to run docker, you will have to install bunch of dependencies, namely flask (which is the error it is showing). Run 'sudo pip3 install flask'.
Running the docker image is easier though.
I've had the same problem. I could not find the home_surveillance folder. I solved the problem. I have run "docker run -v / Users /: / host -p 5000: 5000 -t -i bjoffe / openface_flask_v2 / bin / bash".
I couldn't find the folder I was looking for in the "root @" line, so I created a new folder with the mkdir command.
For example: root @ 49486cf276c6: / # mkdir facerecognition1234
Later in Linux, I found the name facerecognition1234 in the Files application (linux: You can also run "Files" by typing Nemo from the Menu; Windows: file manager) 2 results found for (you can now delete the facerecognition1234 folder)
/ Proc / 6204 / root and / var / lib / docker / aufs / diff / 043ee38a63580f046c7
I moved the home_surveillance folder to one of these folders. Then the problem was solved.
root @ 49486cf276c6: / # cd home_surveillance root @ 49486cf276c6: / home_surveillance # cd system root @ 49486cf276c6: / yuztani / system # python WebApp.py
Türkçe: Ben de aynı sorunu yaşadım. home_surveillance klasörünü bulamadım. Problemi söyle çözdüm. "docker run -v /Users/:/host -p 5000:5000 -t -i bjoffe/openface_flask_v2 /bin/bash" çalıştırdım.
"root@" satırında aradığım klasörü bulamayınca mkdir komutuyla yeni bir klasör oluşturdum.
Örneğin: root@49486cf276c6:/# mkdir facerecognition1234
Daha sonra Linux da Dosyalar uygulamasında facerecognition1234 adını arattırdım (linux: Menü den Nemo yazarak da "Dosyalar" ı çalıştırabilirsiniz; Windows: dosya yöneticisi) karşıma 2 adet sonuç çıktı (facerecognition1234 klasörünü artık silebilirsiniz)
/proc/6204/root ve /var/lib/docker/aufs/diff/043ee38a63580f046c7
home_surveillance klasörünü, bu klasörlerden bir tanesine taşıdım. Daha sonra sorun çözüldü.
root@49486cf276c6:/# cd home_surveillance root@49486cf276c6:/home_surveillance# cd system root@49486cf276c6:/yuztani/system# python WebApp.py
Hello! Thank you for your share, i am successful run it, but i have a question about the "path". When I run the docker, i try to use the command ' python system/WebApp.py ' and the results is ' TemplateNotFound: login.html' . I guess it is problem of path, i found ' join_path' in file environments.py and change it , but it seems didn't work , where should i change and how ? Thank you every much.