First of all, do it for Jesus because His opinion matters.
People can have their opinions. They may think we don't do enough, or we do too much, but their opinions aren't supreme. It's God's opinion that should be the motivation behind everything we do. And it is important to remember that God sees it all. He sees what we do, but He also see how we do it.
"People may be right in their own eyes, but the Lord examines their heart."
Secondly, do it for Jesus because He alone is worthy.
We can get hung up on doing things for people who deserve it. They may not deserve it, but Jesus does. When we are doing it for Jesus we will never feel as if we are working in vain. You know, we can't get caught up on what other people are doing or how they are doing them. You don't have to answer for their action and attitudes. You have to answer for your own.
"And whatever you do or say, do it as a representative of the Lord Jesus, giving thanks through Him to God the Father."
Finally, do it for Jesus because He cares.
Don't get discouraged by all you have done that seems to have gone unnoticed. While they may not have acquired the recognition you would like, just wait. God sees. He knows the sacrifices you have made. And He cares. He cares about the hard work. He cares about what you have accomplished. He cares. People may not care, but it needs to be enough that God does. And when He is who you are doing it for, that's all that will matter.
So let's not get tired of doing what is good. At just the right time we will reap a harvest of blessing if we don't give up.
Keep doing what you're are doing knowing you are doing it for Jesus.
'Truly I tell you, whatever you did not do for one of the least of these, you did not do for me.'