Set boolean configuration parameters correctly from environment

bool('0') evaluates to True, so if we want the resulting variable to be
bool we must first cast to int.