Development of relativistic shock waves in viscous gluon matter