GuidesRecipesAPI ReferenceChangelogDiscussions
Log In

modzy-core register

Registers a device with Modzy

$ modzy-core register [flags] registers a device with an installation of Modzy.

Beginning in version 1.10, the register command must be run before starting core in any manner. Registration verifies the core binary, and registers the device as being part of a device group

During the registration process, Modzy Core will download and cache connection information and any runtime settings the user has specified via core's global flags ( see Modzy Core CLI for a complete list of flags). Where this information is stored on disk depends on how core is run.

The defaults are as follows if no location is specified at runtime using the --storage.filesystem.path flag:

  • /opt/modzy/core if Modzy Core is run as a root user, or Core is unable to determine the user's $HOME directory
  • $HOME/.modzy/ if Modzy Core is run as a non-root user, and Core can determine the $HOME directory

🚧

Be Mindful of the Cache Location

This path is incredibly important, as it is where Modzy Core will look for registration and start-up information. If it fails to find the registration info, core will fail to start.

If a location is specified, be sure to specify that location when installing Core, or starting it in direct or server mode

Usage

Enter the following code into the terminal after making the following replacements:

Replace <https://trial.app.modzy.com> with the URL of your instance of Modzy,
Replace s.dP0JrRSS3AJ38hykhKebl0MG with a valid token
Replace </path/to/registration/info> with the location of where you wish to save core's registration information , or omit this flag altogether to use Core's defaults

$ ./modzy-core register --modzy.url https://trial.app.modzy.com --modzy.token s.dP0JrRSS3AJ38hykhKebl0MG --storage.filesystem.path </path/to/registration/info>

The output is similar to the following:

Register Flags

FlagTypeDescription
--modzy.urlstringUrl of Modzy Platform
--modzy.tokenstringRegistration token