Are you talking about the cartels, or the Border Patrol?
If this is directed to the BP, first of all, none of them have automatic rifles, in fact very few have anything other than sidearms, so they're doing a dangerous job while being forbidden from bringing privately owned weapons.
"I will well and faithfully discharge the duties of the office on which I am about to enter." forbids them from doing their job as they, and we, see fit.
Rather than blaming them, you should recognize that these are guys (and gals) who dedicated their lives to securing our border - most of us did not - and are now tasked with assisting illegal invaders. Quite possibly hell on earth.
Biden Orders 1,500 Soldiers to Southern Border ahead of Title 42 Expiration