Community resilience and the environment