Add support for rhel6.5 and fix the case when BUILDPACK_URL starts with https