Merge branch 'fix/users_ap_id_not_null' into 'develop'

Ensure ap_id column in users table cannot be null

See merge request !2875
18 jobs for develop in 47 minutes and 54 seconds (queued for 5 seconds)