Welcome
Getting Started
How to Guides
Application vs Blocklet
Create Blocklet
Compose Blocklets
Develop Blocklet
User and Passport
Communicate with DID Wallet
Blocklet Storage
Using Blocklet Preferences
Build blocklet for profit [deprecated]
Bundle your blocklet
Manage Blocklet Versions
Publish your blocklet to the world
Deploy your blocklet
Read/Write blockchain in blocklet
Operation and maintenance your blocklet
Reference Guides
Conceptual Guides
Frequently Asked Questions
Permission Issues on Linux
Usually, it's recommended to run blocklet server as a non-root user for security reasons, and you should always use the same user that created the server to start/stop the server because those who created the server are granted permission to read/write to the blocklet server directory.
You may encounter issues when switching back and forth between different users when init/start/stop your blocklet server, use the following steps:
ubuntu@fnm:~$ sudo blocklet server init -y // the server is initialized by root
ubuntu@fnm:~$ blocklet server start // then non-root user try to update data in server directory during start
If we flip the above steps:
ubuntu@fnm:~$ blocklet server init -y // the server is initialized by non-root
ubuntu@fnm:~$ sudo blocklet server start // then root user try to update data in server directory during start
You may encounter permission issues in all the above scenarios because the server creator is not the same as blocklet server starter.
So, to keep things clean and tidy, just stick to the same user that created the server to do any furthur operations.