Skip to content

Commit

Permalink
Write screenshots to /tmp/screenshot.png instead of /var/www/screensh…
Browse files Browse the repository at this point in the history
…ot.png

Fixes #37

/var/www is now owned by root instead of ftc because changing the owner caused the image build to fail because the new symlink /var/www/screenshot.png -> /tmp/screenshot.png does not have a target in the build system, and the only reason why it had to be owned by ftc was writing screenshots.
  • Loading branch information
rkunze committed May 3, 2016
1 parent 1f05530 commit 776339f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion board/fischertechnik/TXT/device_table.txt
Expand Up @@ -8,7 +8,6 @@
# apps still belong to root and thus cannot be touched by ftc
#
# <name> <type> <mode> <uid> <gid> <major> <minor> <start> <inc> <count>
/var/www r 755 1001 1001 - - - - -
/opt/ftc/apps d 755 1001 1001 - - - - -
/rom d 755 0 0 - - - - -
/opt/fischertechnik r 755 1000 1000 - - - - -
Expand Down
Binary file not shown.
1 change: 1 addition & 0 deletions board/fischertechnik/TXT/rootfs/var/www/screenshot.png
4 changes: 2 additions & 2 deletions board/fischertechnik/TXT/rootfs/var/www/screenshot.py
Expand Up @@ -19,9 +19,9 @@
# for PC based tests use imagemagicks import to grab the X screen. The user
# ownign the screen needs to give access with "xhost +" beforehand
if platform.machine() == "armv7l":
COMMAND = "fbgrab screenshot.png"
COMMAND = "fbgrab /tmp/screenshot.png"
else:
COMMAND = "import -display :0 -window root -geometry 320x240 screenshot.png"
COMMAND = "import -display :0 -window root -geometry 320x240 /tmp/screenshot.png"

app = subprocess.Popen(COMMAND.split())
while app.poll() == None:
Expand Down

0 comments on commit 776339f

Please sign in to comment.