Again the people find fault with Moses because there is no water to drink (Exodus 17:1-7 ). Still they complain and fail to trust. How prone we are to fail in the same way. In answer to the cry of Moses the Lord again in grace intervenes. The smitten rock brings forth New Testament truth.
As such He is our shelter, safety, strength, supply. The Lord said,
Exodus 17:6 "Behold, I will stand before you there on the rock ...".
God was in Christ (2 Corinthians 5:19 ). The rock would be as dry as the desert it was part of, but God on the rock and in the rock, could do anything. The source of living water is both Lord and Christ. (Acts 2:36 ).
"You shall strike the rock." "He was wounded for our transgressions, He was bruised for our iniquities." Isaiah 53:5. Smitten vicariously for us. "Wounded = pierced, a term appropriate to crucifixion." Ryrie
Exodus 17:5 "Also take in your hand your rod with which you struck the river,"
The rod of judgment that had turned the river to blood.
Isa 53:10 "Yet it pleased the Lord to bruise Him; He has put Him to grief. When you made His soul an offering for sin..."
Psalm 78:20 "Behold, he struck the rock, so that the waters gushed out, and the streams overflowed."
1 Corinthians 10:4 "And all drank the same spiritual drink. For they drank of that spiritual Rock that followed them, and that Rock was Christ."
"Rabbinic legend held that a material rock actually followed the Israelites. Paul, however, says that it was Christ who was with Israel all the way." Ryrie
So the Lord is with us - His supply is always available.

What right action of Moses is it safe for you to follow?
How did God respond to Moses and the need of the people?