You can use finishing nails or glue (liquid nail), although finishing nails is recommended, as usually ceiling and walls are not 100% straight, then is this case nails help better to attach the pieces of moldings without leaving gaps, nails can be hidden by placing them into the design deeps (dark areas), most of the time touch up is not necessary.