create file API v2 and X-Accel-Redirect endpoint for images
This commit is contained in:
parent
ab5e8f36d1
commit
77828295f8
10 changed files with 164 additions and 1 deletions
|
@ -16,6 +16,8 @@ class FileViewSet(viewsets.ModelViewSet):
|
|||
serializer_class = FileSerializer
|
||||
queryset = File.objects.all()
|
||||
lookup_field = 'hash'
|
||||
permission_classes = []
|
||||
authentication_classes = []
|
||||
|
||||
|
||||
router = routers.SimpleRouter(trailing_slash=False)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue