As a youth, Gruber belonged to the Zionist organizations Hashomer Hatzair and HeHalutz.
When he was 14, Gruber went to Lwów, Poland (now Lviv, Ukraine) to attend high school.
He then returned to Podhajce where he worked as a bookkeeper for a company that manufactured farm equipment and bicycles.
After a month in the hospital, Gruber and the other prisoners were transported to Stalag 13, a camp in Langwasser, Germany, near Nuremberg.
Gruber was assigned to work in an office of a hospital that distributed uniforms, rifles and pistols to German soldiers coming from the front.
His group eventually joined the Parczew partisans and fought the Germans while attempting to save as many Jewish lives as possible.
He was made head of a displaced persons camp for children at Prien am Chiemsee, Germany in 1947.