api/PostPolicy: Allow location header fully qualified URL (#4926)

req.Host is used to construct the final object location.

Fixes #4910
This commit is contained in:
Harshavardhana
2017-09-24 16:43:21 -07:00
committed by Dee Koder
parent c3ff402fcb
commit 4cadb33da2
5 changed files with 99 additions and 17 deletions
+1 -6
View File
@@ -101,12 +101,7 @@ func newNotificationEvent(event eventData) NotificationEvent {
host = localIP4.ToSlice()[0]
}
scheme := httpScheme
if globalIsSSL {
scheme = httpsScheme
}
return fmt.Sprintf("%s://%s:%s", scheme, host, globalMinioPort)
return fmt.Sprintf("%s://%s:%s", getURLScheme(globalIsSSL), host, globalMinioPort)
}
// Fetch the region.