Some questions for ftp upload:
How does a process check if a file upload is complete?
(FTP has) no integrity check on the receiver side. If a transfer is interrupted, the receiver has no way to know if the received file is complete or not. Some servers support extensions to calculate for example a file's MD5 sum (e.g. using the SITE MD5 command) or CRC checksum, however even then the client has to make explicit use of them. In the absence of such extensions, integrity checks have to be managed externally.
- Users that close connection and leave unfinished files behind, should solve this themselves. Solution could be to use ffmpeg to check video-file-validity.
User management connected to sponge users in db
- FTP daemon has to use external user/authentication management.
- PureFTP documentation: mysql or postgreSQL user management:
Here's a sample configuration file:
PGSQLGetPW SELECT "Password" FROM "users" WHERE "User"='L'
PGSQLGetUID SELECT "Uid" FROM "users" WHERE "User"='L'
PGSQLGetGID SELECT "Gid" FROM "users" WHERE "User"='L'
PGSQLGetDir SELECT "Dir" FROM "users" WHERE "User"='L'
- FTP daemon has to allow access only to private/home incoming dir.
Covered by PureFTPd (chroot options).
Troubles while installing
The /etc/init.d/pure-ftpd script is broken and does not start the pure-upload script. So i edited it and added:
UPLOADSCRIPT=/sponge/Sponge/python/sponge/storage/upload-complete.py # path to upload script!
if [ "$UPLOADSCRIPT" ...
Upload script n