At a precarious moment for his immigration policy, President Obama took part in a naturalization ceremony Friday for 16 members of the armed forces, two veterans and seven military spouses, saying he will take action so that “hardworking” immigrants who come to the United States can “join the American family.”

After Alejandro Mayorkas, deputy secretary of homeland security, delivered the oath of citizenship in an East Room ceremony, Obama alluded only generally to the decisions he faces after House Republicans formally told him that a comprehensive overhaul of immigration laws will not occur this year in Congress.

“As long as there are men and women like all of you who are willing to give so much for the right to call yourselves Americans, and as long as we do our part to keep the door open to those who are willing to earn their citizenship, then we’re going to keep on growing our economy, we’ll continue to journey forward, and we’ll remind the world of why the United States of America is and always will be the greatest nation on Earth,” he said during the Independence Day event.

The rhetoric was far more sweeping than the practical choices Obama must make in the coming months. He has pledged to use his executive authority to strengthen border security while potentially slowing the deportation of longtime illegal immigrants with no connection to criminal behavior beyond immigration violations.

Immigration activists want him to take dramatic action to end deportations for many of these people, but White House officials have warned it would be difficult to do that within the law.

Still, Obama espoused the broad ideals of welcoming all kinds of immigrants at the naturalization ceremony, which he has held several times since becoming president.

“The basic idea of welcoming immigrants to our shores is central to our way of life. It is in our DNA,” Obama said. “We believe our diversity, our differences, when joined together by a common set of ideals, makes us stronger, makes us more creative, makes us different. From all these different strands, we make something new here in America.

“And that’s why, if we want to keep attracting the best and brightest from beyond our borders, we’re going to have to fix our immigration system, which is broken, and pass common-sense immigration reform,” he said.