CFY-1199 adjust scripts to use ctx