Turn Instant Pot to sauté. While it comes up to heat, mince the garlic, slice the shallots and slice the mushrooms.
When the pot is hot, add the bacon. Sauté until just crispy - about 3 minutes.
Add the mushrooms, shallots and garlic to the pan and sauté until the onions release their moisture - about 5 minutes.
Pour in the chicken stock and scrape up any brown bits.
Add the green beans and stir to coat.
Press cancel to turn off the sauté function. Lock on the lid and turn the venting valve to sealed. Use the manual setting to set the time for 3 minutes.
When the timer beeps, release the pressure and open the lid carefully away from you. Taste and add salt and pepper.
Video
Notes
To easily dice the bacon, use kitchen shears and snip it right into the pot! These green beans are tender with still a bit of bite, if you like yours a little softer, set the timer for 7 minutes.