Django + AWS Elastic Transcoder
Install
First, install dj_elastictranscode with pip
$ pip install django-elastic-transcoder
Then, add dj_elastictranscoder to INSTALLED_APPS
INSTALLED_APPS = (
...
'dj_elastictranscoder',
...
)
Bind urls.py
urlpatterns = patterns('',
...
url(r'^dj_elastictranscoder/', include('dj_elastictranscoder.urls')),
...
)
Migrate
$ ./manage.py migrate
Setting up AWS Elastic Transcoder
Create a new Pipeline in AWS Elastic Transcoder.
Hookup every Notification.
Subscribe SNS Notification through HTTP
You are ready to encode!
Usage
For instance, encode an mp3
from dj_elastictranscoder.transcoder import Transcoder
input = {
'Key': 'path/to/input.mp3',
}
outputs = [{
'Key': 'path/to/output.mp3',
'PresetId': '1351620000001-300040' # for example: 128k mp3 audio preset
}]
pipeline_id = '<pipeline_id>'
transcoder = Transcoder(pipeline_id, 'ap-southeast-1')
transcoder.encode(input, outputs)
Release files for django-elastic-transcoder 0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| django-elastic-transcoder-0.2.tar.gz | 4.6 kB | Details |
Release files / django-elastic-transcoder-0.2.tar.gz
| Download URL | django-elastic-transcoder-0.2.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7c089035193657da5b256140572288bf66fe3a8ebdffd820f7e89e524aa93d8d
|
|
BLAKE2b-256 checksum How to use checksums |
c963a1214523bb291e23b69a9877817df2ed9ec79a188bfd0539417748247453
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |