added logic to set application status based on container status