here’s a tip from a busy bike workshop 😉
remove the pads and spring, grab the brake lever and pump the pistons out a little (not so far as to have them pop out)
if you find one piston moves out and the other sits still, use a 10mm ring spanner to retain the moving piston, this will apply pressure to the static one and get it moving
once both pistons have some exposed depth, use a silicon grease or spray lube (Fork Juice is ideal) on the piston’s diameter, and then push the pistons back into the caliper with the ring spanner, wipe any excess off the exposed face of the pistons
install the pads / spring and go ride..
this effectively lubricates the piston body and piston seal with silicon, which has enough heat resistance to not become mobile and leak onto the pads once the brake gets hot
you can get DOT specific silicon rebuild grease (Avid offer this) but general silcon grease (RS) or spray works just fine 😉