(CNN) — A New Zealand council has announced a month-long road closure in order to allow a sea lion and her pup to reach the ocean safely. John Wilson Ocean Drive in Dunedin will be closed after the New Zealand sea lions made their home at a nearby golf course and started "regularly crossing the road to get to the beach," according to a Facebook post from Dunedin City Council published Monday.
"You can still visit the area by foot or bicycle, but please give the sea lions lots of space (at least 20m)," continued the post.
"If you're walking your dog in the area, please keep it on a lead as sea lions can be hard to spot."
Dunedin is the second-largest city on New Zealand's South Island.
Locals commenting on the post applauded the decision, and one even called for the closure to be made permanent.
"No dogs should be on the beach either," wrote Gaylene Smith. "We need to protect our beautiful sealife."
Dogs are known to attack sea lions, and Chisholm Links Golf Course, where the sea lions have made their home, also posted advice to dog walkers in a Facebook update.
"We're lucky to have marine mammals on our coastline and we need to share the space with them, as this is what makes our coastal Links and Dunedin's coastline so unique!" wrote the course on Facebook on January 5.
The council went on to explain that New Zealand sea lions are endangered, and one of the world's rarest species of sea lion.
There are an estimated 12,000 New Zealand sea lions left, according to the Department of Conservation. Under local law, anyone who kills a sea lion could face up to two years in prison or a fine of up to NZ$250,000 (US$178,000).
In December 2019 a Dunedin man sparked anger after spearing a sea lion while diving.
Matt Kraemer posted on Facebook that he and his partner were diving for paua -- a type of abalone -- on Friday when they encountered a "particularly aggressive" sea lion with "lion-sized jaws."
Kraemer said he stabbed the sea lion to protect his partner, but his actions were roundly condemned.