According to the (canon) Star Wars: Battles that Changed the Galaxy factbook, the Ewoks were already planning some sort of military incursion against the bunker before the arrival of Leia's rebels.
However, though they were elite soldiers, the Imperial forces at the
bunker had paid scant attention to the supposedly “primitive” Ewok
species who were indigenous to the moon. The Empire had not noticed
the Ewoks’ fiercely proud warrior culture, or that they had been
preparing defensive positions around the bunker for several weeks.
When the Ewoks attacked, the Imperial military found themselves
fighting from a surrounded position against an enemy who had prepared
the battlefield against them. While the Empire possessed a marked
technological advantage it was effectively nullified by an adversary
who knew the terrain and could seemingly disappear at will.
...
They would not engage the Empire directly, but instead prepared a
series of traps around the bunker just in case an opportune moment
arose. Having been won over to the rebels’ cause by stories of their
past heroism, the Ewoks decisively intervened in the ground combat
outside the shield bunker. While they defeated the stormtroopers, the
battle also cost many Ewoks their lives.
The Ewoks were certainly offended by the presence of the Imperials but the concept of an organised "rebellion" (and the need for an all-out assault, regardless of the potential for loss of life) doesn't seem to have been considered until Leia and her merry band of anti-government terrorists turned up to lead them into battle. C-3PO tells them about the wider conflict that has been raging in the Galaxy and explains that the Ewoks find themselves at a critical juncture.
Chief Chirpa organises for Ewoks from other tribes to join him in attacking the base
Things are said that are not cute. The Ewoks are talking of battle, of
weapons and traps and death.
These are fierce creatures. Predators. The top of the food chain in a
deadly forest. And they are ready to kill.
For, you see, now that the Ewoks understand that our heroes are in
fact heroes—and are there to destroy the cursed biker scouts and blow
up the great metal mess in the sky—they are eager to help. They had
known nothing of the great galactic struggle for freedom that the
Rebellion had carried on for decades. But, Chirpa reminds them, they
did know that a great evil had come to their forest. He recalls the
tribe members killed by the Empire’s soldiers and metal monsters.
Return of the Jedi: Beware the Power of the Dark Side
After Leia's speech, they had the entire village (several hundred Ewoks) spending the night getting the battlefield ready for the assault.
WHEN OUR HEROES AWAKE, they find the village nearly deserted. There
were an abundance of very young and very old Ewoks, but all those able
to join the fight had risen and followed Chirpa, Teebo, and Asha into
the forest. There was much work to be done.
ewoks
tag unfortunately.