Skip to main content

A ftrack s3 accessor updated to work with ftrack-python-api and boto3.

Project description

ftrack-s3-accessor

An ftrack s3 accessor updated to work with ftrack-python-api and boto3.

Requirements:

  • boto3 - if used standalone
  • ftrack-action-handler (optional) - if used with the transfer components action found here

Installation

Install python using pyenv:

pyenv install

Install dependencies using pipenv (and python pyenv from above):

pipenv install --python $(pyenv which python)

Note: To be able to make use the transfer components action, and be compatible with ftrack-connect the pipenv uses python 2.7. It works using other versions of python - remove the Pipfile.lock and the transfer_component dependency from the Pipfile, update the python version in .python-version and the Pipfile and re-run the install command.

Configuration

Configure a new location within ftrack with the name 'studio.remote'. This will be used as the location for s3.

Create a storage bucket in s3 and set the bucket name using the FTRACK_S3_ACCESSOR_BUCKET environment variable (default: ftrack). Ensure your bucket name is globally unique and meets aws s3 naming restrictions.

Set all other ftrack environment variables for your ftrack instance. You can do so using an .env file for all your env vars which will automatically be loaded by pipenv when running scripts.

Running the scripts from within your pipenv requires you to additionally set your sources root to the accessor directory within your .env file.

PYTHONPATH=./accessor` 

Ensure you have an working aws configuration under your ~/.aws folder. You can check this by running:

pipenv run python

and then running:

import boto3

If this fails, your aws configuration isn't setup properly. Refer to the boto3 documentation on how to set it up. You should only need a ~/.aws/config and ~/.aws/credentials file.

Usage

The main plugin can be found in the plugins folder. This folder may be registered using the FTRACK_EVENT_PLUGIN_PATH ftrack environment variable so that it is picked up when ftrack is started.

Examples of how to use the plugin can be found in the scripts folder. The simplest way to launch ftrack with the accessor correctly pre-configured is:

pipenv run start

Which will launch the start_ftrack_with_s3.py script.

It is possible to use the transfer components action to move components between local and remote storage. Ensure it is on the FTRACK_EVENT_PLUGIN_PATH (or add it to the plugins folder) and it should become available under ftracks actions menu. You will need to ensure your local storage is also correctly configured within a script when running the accessor outside of ftrack-connect, as the connect location configured by the desktop client will not be available as an option.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ftrack-s3-accessor-0.1.5.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ftrack_s3_accessor-0.1.5-py2.py3-none-any.whl (5.6 kB view details)

Uploaded Python 2Python 3

File details

Details for the file ftrack-s3-accessor-0.1.5.tar.gz.

File metadata

  • Download URL: ftrack-s3-accessor-0.1.5.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.0 CPython/3.8.3 Linux/5.4.0-49-generic

File hashes

Hashes for ftrack-s3-accessor-0.1.5.tar.gz
Algorithm Hash digest
SHA256 f1e2d67982f1705fc87fa211d1d2529af4fd7e2fbf4c66c847c2363239db121a
MD5 6c85295d9e571177a6e18f731488e561
BLAKE2b-256 c8a6f75cd4505b9744894517e69f2b8e7b0ac964dc507d20968790540a05f75a

See more details on using hashes here.

File details

Details for the file ftrack_s3_accessor-0.1.5-py2.py3-none-any.whl.

File metadata

  • Download URL: ftrack_s3_accessor-0.1.5-py2.py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.0 CPython/3.8.3 Linux/5.4.0-49-generic

File hashes

Hashes for ftrack_s3_accessor-0.1.5-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 7f38a69a22aaf08a9ecb90121987369504ed9d3ea2df081282549e65b1f71c3d
MD5 c29365d9d83a765f0b0ef75007cf9cf4
BLAKE2b-256 03aea1204026b24d60fd8a710fadb1e04e9d1db6a44ead32cb743c7a9bedd1a6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page