refactor code so when gush becomes container aware we will not have to change much code