Assuming the eight doesn't pass the nine, this is a tough runout.
I believe an accomplished player would cut the seven in the side with low inside and go to the top rail and then the long rail just under the nine to move the nine and set up a shot on the eight in the corner. That choice has a pretty big downside, though, because if your speed is wrong or you catch the wrong part of the nine, you can wind up hooked. If you add speed, you're far less likely to end up hooked, but also less likely to set up an easy shot on the eight.
Another option is to play shape to bank the eight. If you want to bank it in the side, you can play shape for that. If you want bank it in the corner, you can play shpae that. The bank of the eight in the corner is a little more diffcult than the bank in the side but as it can be played two ways (with defense) it would be a reasonable choice.
Finally, you can play shape for the eight-nine combo into the corner. This combo, which requires driving the eight into the rail so that it comes off at the correct angle to knock the nine in, is easier than it looks, and if you don't know it, you should practice it.
Anyway, you got out here, so nice shooting!