-
-
Save MerlinDMC/82bda750b210f2ab5a58 to your computer and use it in GitHub Desktop.
dsapid create first user and upload datasets
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create admin user | |
# needs to be run via 127.0.0.1 to be accepted as an authenticated administrative command | |
curl -v -X PUT http://127.0.0.1/api/users -d '{ "name": "admin", "token": "admintoken", "type": "user", "roles": [ "s_dataset.upload", "s_dataset.manage", "s_dataset.admin" ] }' | |
# upload a dataset | |
curl -v -u admintoken: http://dsapid.example.com/api/upload -F manifest=@image.dsmanifest -F file=@image.zfs.gz | |
# make an upload public | |
curl -v -X POST -u admintoken: http://dsapid.example.com/api/datasets/b1f1827e-88f6-11e4-9392-770a880c2693?action=enable |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment