Added support for Swift shoebox handler

This commit is contained in:
Sandy Walsh 2014-06-03 03:46:20 +00:00
parent 45002fb79e
commit bb0656d7b6
3 changed files with 24 additions and 1 deletions

View File

@ -21,3 +21,10 @@ with the `shoebox.conf` configuration file. This will read events from
the rabbit queue and save them to local files. The working directory
and archive directory for `shoebox` is specified in `shoebox.conf`.
The sandbox environment configures `shoebox` to upload archive files
to Swift automatically. This requires you create a credentials file
in the `.../sandbox/` directory (like in
`.../git/sandbox/etc/sample_rax_credentials.conf`) Call it
`swift_credentials.conf` or alter the `shoebox.conf` file accordingly. If
you don't have access to a Swift server, like CloudFiles, read
the config file for details on disabling this feature.

View File

@ -30,9 +30,12 @@ source ./$VENV_DIR/bin/activate
# Some extra required libs ...
pip install librabbitmq
# Needed by pyrax:
pip install pbr
for file in $SOURCE_DIR/*
do
echo "----------------------- $file ------------------------------"
cd $file
rm -rf build dist
python setup.py install

View File

@ -43,6 +43,19 @@ destination_folder=../../../data/archive
filename_template=events_%Y_%m_%d_%X_%f.dat
roll_checker=shoebox.roll_checker:SizeRollChecker
roll_size_mb=1
callback=shoebox.handlers:MoveFileCallback
distiller_conf=../../../distiller.conf
# Swift upload support
# create a credentials file (see shoebox/bin/sample_credentials.conf)
callback=shoebox.handlers:CallbackList
callback_list=shoebox.handlers:MoveFileCallback, shoebox.handlers:SwiftUploadCallback, shoebox.handlers:DeleteFileCallback
container=sandbox
credentials_file=../../../swift_credentials.conf
auth_method=rackspace
region=DFW
# If you don't want Swift support, comment the above callback=
# entry and uncomment this one:
#callback=shoebox.handlers:MoveFileCallback
# which will just move the file into the archive directory.