Chop the onion and garlic, slice the green onions, drain the pineapple, beat the eggs, and separate the cold rice into loose grains.
Heat 1 tablespoon oil in a wok or large skillet over medium-high heat. Add eggs and scramble until just set. Remove and set aside.
Add 1 tablespoon oil to the pan. Add chicken in a single layer and stir-fry until fully cooked and lightly golden.
Add remaining oil if needed. Cook onion for 1–2 minutes until soft, then add garlic and cook until fragrant.
Add cold jasmine rice and break apart any clumps. Stir-fry on high heat until heated through and slightly toasted.
Stir in pineapple, soy sauce, fish sauce, sugar, and white pepper. Toss until evenly coated.
Return eggs and chicken to the pan. Add green onions and drizzle with sesame oil. Toss briefly, remove from heat, garnish with cilantro if desired, and serve hot.