Ammonia will discourage the critters, probably racoons. Just pour a quarter to half cup over the trash in the container and close the lid. Repeat every day or two, they get the message.
I got tired of dealing with them, so I called Barbara at Good Neighbor Services, she comes right into the garage to get the trash so I don't worry about the bears and racoons any more.
http://goodneighborservicesnh.com/