You could apply early and see what happens, but according to the rules you may be denied if you apply when your expiration date is not within 6 months.
A workaround strategy which avoids that risk would be to apply for a reentry permit now, then apply for GC renewal sometime after you return to the US. A reentry permit is normally valid for 2 years, and can be used to reenter the US even if your GC is expired or lost. And the reentry permit is a multiple-use document, so for travel purposes you wouldn't need to renew the GC for the next 2 years (unless another country you'll visit requires you to have a valid GC before they issue you a visa or let you enter without a visa).
The permit can be delivered to your US address, or to a US consulate in the country of your choosing where you'd pick it up when it's ready.
Note that you must be in the US when you file the reentry permit application, including when USCIS receives it, and the reentry permit requires biometrics.