Migrating from 5.x to 7.x ocis init --diff not working

Steps to reproduce

  1. Start 5.x container
  2. Run ocis init --diff
  3. Get response Could not create config: diff and admin-password flags are mutually exclusive

Expected behaviour

The CLI tool should respond with a config diff according to the 5.x to 7.x migration instructions.

Actual behaviour

See point 3 above.

Server configuration

Operating system: Linux
Where did you install ownCloud from: owncloud/ocis container image

Why is the CLI responding with this message when I try to run ocis init --diff, and what can I do about it?

The diff option will not work when setting a admin password too. This is because the admin password can only be set once.

You probably have either ADMIN_PASSWORD or IDM_ADMIN_PASSWORD set. So something like IDM_ADMIN_PASSWORD="" ocis init --diff should fix the problem.