Microservices have been proposed as the software architecture style for fog-IoT network applications ecosystems. Recently, microservices have been extensively used in fog-IoT ecosystems. Here, master-worker fog-based frameworks have been widely adopted in the ecosystem to ensure resilience. However, the architecture's reliability, including the possibility of the master fog node failure, and service unavailability, is not reflected adequately in the literature. Therefore, we present a resilient master-citizen fog-IoT framework to ensure efficient resource management and overall system reliability. In this work, we develop a master fog node and layered citizen nodes in the distributed ecosystem. Our fault-tolerant fog-IoT-based microservice execution framework can ensure efficient recovery from a single point of failure, unavailability, and unexpected events in the master fog node, which means the network can continue working after a system failure. We use different fault-tolerance strategies and algorithms for selecting the master fog node that synchronizes with other citizen fog nodes and the upper layer cloud for efficient microservice execution. Finally, we developed and implemented a resilient fog-IoT network for providing uninterrupted services in the event of master fog node failure.