First, if the officer was a state commissioned officer, even though he might be out of his usual jurisdiction and out of uniform his legal authority is statewide. Second, if he allowed you to stand up and leave without further incident, he almost certainly either accepted your explanation that you had permission of the contractor who owned or rented the dumpster, which would be all the authority you would need to be there. In theory, the appropriate police or sheriff's department could investigate and, if they decide there was some criminal conduct, either cite you or arrest you accordingly. But given that the officer did not pursue you at the time, this is very unlikely. Making it even more unlikely is that the officer in question probably does not want to bother further with the matter and have to explain his actions outside his normal jurisdiction. Chances are very high that you have nothing further to worry about from this somewhat odd incident.
The foregoing is intended as legal information concerning the question asked, but is not intended as legal advice upon which the requesting party may rely in guiding their actions. Rather, the requesting party should consult an attorney for a personal consultation and advice for a full consideration of their situation and rendition of legal advice. Additionally, by providing this general information I am not accepting any representation of the requesting party and I am specifically declining to form an attorney-client relationship with the requesting party unless agreed to later after further consultation and agreement.
Areas of practice listed are are areas of concentration in my practice. I am not board certified in any of the listed areas, and by listing them and describing my practice I am merely describing my experience and the nature of my practice.