Apache 2.4 compatibility

I copied the conditional statement from the original template to make this cookbook play nice with Apache 2.4