Welcome! Log In Create A New Profile

Advanced

How to validate against S3 for file existance

Posted by shija03 
How to validate against S3 for file existance
February 25, 2016 12:39PM
I want to use NGINX as a director where the following logic would take place:

+ Request for an asset comes from the web

++ Taking the path of the file - check if this file is already under my s3 bucket -http://$s3_bucket/$url_full

+++ If file exists then redirect the request to "http://$s3_bucket/$url_full"
+++ If file does not exist then serve it directly from the local drive and trigger a shell command.

Thank you for any help on this.



Edited 1 time(s). Last edit at 02/25/2016 12:40PM by shija03.
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 155
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready