--- /dev/null
+FROM arvados/base
+MAINTAINER Peter Amstutz <peter.amstutz@curoverse.com>
+
+RUN apt-get update -qq
+RUN apt-get install -qqy \
+ apt-utils git curl procps apache2-mpm-worker \
+ libcurl4-openssl-dev apache2-threaded-dev \
+ libapr1-dev libaprutil1-dev
+
+# Install apache configuration...
+
+ADD apache2_vhost /etc/apache2/sites-available/arv-web
+RUN \
+ a2dissite default && \
+ a2ensite arv-web && \
+ a2enmod rewrite
+
+ADD apache2_foreground.sh /etc/apache2/foreground.sh
+
+CMD ["/etc/apache2/foreground.sh"]
\ No newline at end of file
--- /dev/null
+#! /bin/bash
+
+read pid cmd state ppid pgrp session tty_nr tpgid rest < /proc/self/stat
+trap "kill -TERM -$pgrp; exit" EXIT TERM KILL SIGKILL SIGTERM SIGQUIT
+
+source /etc/apache2/envvars
+/usr/sbin/apache2 -D FOREGROUND
--- /dev/null
+<VirtualHost *:80>
+
+ ServerName arv-web
+ ServerAdmin sysadmin@curoverse.com
+
+ # Index file and Document Root (where the public files are located)
+ DirectoryIndex index.html
+ DocumentRoot /mnt
+
+ LogLevel warn
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+
+ <Directory /mnt>
+ Options Indexes FollowSymLinks MultiViews IncludesNoExec
+ AllowOverride None
+ Order allow,deny
+ allow from all
+ </Directory>
+
+</VirtualHost>
import arvados
import subprocess
-from arvados_fuse import Operations, SafeApi, MagicDirectory
+from arvados_fuse import Operations, SafeApi, CollectionDirectory
import tempfile
import os
import llfuse
global project
global evqueue
- old_attr = None
- if 'old_attributes' in ev['properties'] and ev['properties']['old_attributes']:
- old_attr = ev['properties']['old_attributes']
- if project not in (ev['properties']['new_attributes']['owner_uuid'],
- old_attr['owner_uuid'] if old_attr else None):
- return
-
- et = ev['event_type']
- if ev['event_type'] == 'update' and ev['properties']['new_attributes']['owner_uuid'] != ev['properties']['old_attributes']['owner_uuid']:
- if args.project == ev['properties']['new_attributes']['owner_uuid']:
- et = 'add'
- else:
- et = 'remove'
-
- evqueue.put((project, et, ev['object_uuid']))
+ import pprint
+ pprint.pprint(ev)
+
+ if 'event_type' in ev:
+ old_attr = None
+ if 'old_attributes' in ev['properties'] and ev['properties']['old_attributes']:
+ old_attr = ev['properties']['old_attributes']
+ if project not in (ev['properties']['new_attributes']['owner_uuid'],
+ old_attr['owner_uuid'] if old_attr else None):
+ return
+
+ et = ev['event_type']
+ if ev['event_type'] == 'update' and ev['properties']['new_attributes']['owner_uuid'] != ev['properties']['old_attributes']['owner_uuid']:
+ if args.project == ev['properties']['new_attributes']['owner_uuid']:
+ et = 'add'
+ else:
+ et = 'remove'
+
+ evqueue.put((project, et, ev['object_uuid']))
filters = [['owner_uuid', '=', project],
['uuid', 'is_a', 'arvados#collection']]