It seems unlikely that Jesus was a Gnostic although Jewish sects at the time of Jesus had very similar features to later Christian Gnostic cults. There is actually a debate among scholars if Christian Gnosticism originated from these Jewish beliefs. It would all come down if Jesus ever existed at all.