create user and group before directories

The user and group need to be created before the directories can be created, which should belong to them.