./uplink.exe share [ALLOWED_PATH_PREFIX]... [flags]
uplink share [ALLOWED_PATH_PREFIX]... [flags]
uplink share [ALLOWED_PATH_PREFIX]... [flags]
An access generated using uplink share
with no arguments creates an access to your entire project with read permissions.
Flag | Description |
| the serialized access, or name of the access to use |
| url for shared auth service Asia https://auth.ap1.storjshare.io |
| the base url for link sharing Asia https://link.ap1.storjshare.io |
| if true, disallow deletes |
| if true, disallow lists |
| if true, disallow reads |
| if true, disallow writes |
| specify your custom hostname. if set, returns dns settings for web hosting. implies |
| path to export the shared access to |
| help for share |
| disallow access after this time (e.g. '+2h', '2020-01-02T15:01:01-01:00') |
| disallow access before this time (e.g. '+2h', '2020-01-02T15:01:01-01:00') |
| if true, the access will be public. |
| implies |
| if true, creates and registers access grant |
| if true, returns a url for the shared path. implies |
| implies |
./uplink.exe share sj://cakes/cheesecake.jpg
uplink share sj://cakes/cheesecake.jpg
uplink share sj://cakes/cheesecake.jpg
Notice that by default, only download (read) and list operations are allowed.
=========== ACCESS RESTRICTIONS ==========================================================Download : AllowedUpload : DisallowedLists : AllowedDeletes : DisallowedNotBefore : No restrictionNotAfter : No restrictionPaths : sj://cakes/cheesecake.jpg=========== SERIALIZED ACCESS WITH THE ABOVE RESTRICTIONS TO SHARE WITH OTHERS ===========Access : 12yUGNqdsKX1Xky2qVoGwdpL...
./uplink.exe share sj://cakes/ --readonly=false
uplink share sj://cakes/ --readonly=false
uplink share sj://cakes/ --readonly=false
As the --readonly
flag is set to false, uploads and deletes are allowed.
=========== ACCESS RESTRICTIONS ==========================================================Download : AllowedUpload : AllowedLists : AllowedDeletes : AllowedNotBefore : No restrictionNotAfter : No restrictionPaths : sj://cakes/=========== SERIALIZED ACCESS WITH THE ABOVE RESTRICTIONS TO SHARE WITH OTHERS ===========Access : 12BncZWg9xc4GyXCgCi3YvBg...
Generate credentials to use with our S3 multitenant gateway (beta): GatewayMT
./uplink.exe share sj://cakes/ --register --auth-service=https://auth.us1.storjshare.io
uplink share sj://cakes/ --register --auth-service=https://auth.us1.storjshare.io
uplink share sj://cakes/ --register --auth-service=https://auth.us1.storjshare.io
Notice the endpoint generated for Gateway MT gateway.us1.storjshare.io
corresponds to the auth service used auth.us1.storjshare.io
=========== ACCESS RESTRICTIONS ==========================================================Download : AllowedUpload : DisallowedLists : AllowedDeletes : DisallowedNotBefore : No restrictionNotAfter : No restrictionPaths : sj://cakes/ (entire bucket)=========== SERIALIZED ACCESS WITH THE ABOVE RESTRICTIONS TO SHARE WITH OTHERS ===========Access : 1Q74vfxunqiAQ15WPxPqreya...========== CREDENTIALS ===================================================================Access Key ID: jvguri...Secret Key : j3nj4x...Endpoint : https://gateway.us1.storjshare.io
You can also generate a URL to share your projects/buckets/objects
./uplink.exe share sj://cakes/ --url --auth-service=https://auth.us1.storjshare.io --base-url=https://link.us1.storjshare.io
uplink share sj://cakes/ --url --auth-service=https://auth.us1.storjshare.io --base-url=https://link.us1.storjshare.io
uplink share sj://cakes/ --url --auth-service=https://auth.us1.storjshare.io --base-url=https://link.us1.storjshare.io
Notice that the auth service URL auth.us1.storjshare.io
, linksharing base URL link.us1.storjshare.io
, and gateway endpoint gateway.us1.storjshare.io
all correspond.
=========== ACCESS RESTRICTIONS ==========================================================Download : AllowedUpload : DisallowedLists : AllowedDeletes : DisallowedNotBefore : No restrictionNotAfter : No restrictionPaths : sj://cakes/ (entire bucket)=========== SERIALIZED ACCESS WITH THE ABOVE RESTRICTIONS TO SHARE WITH OTHERS ===========Access : 1Q74vfxunqiAQ15WPxPqreya...========== CREDENTIALS ===================================================================Access Key ID: jvguri...Secret Key : j3nj4x...Endpoint : https://gateway.us1.storjshare.ioPublic Access: true=========== BROWSER URL ==================================================================REMINDER : Object key must end in '/' when trying to share recursivelyURL : https://link.us1.storjshare.io/s/jvguri.../cakes
Also note that the URL uses the same Gateway MT access key, so if you have that already, you don't necessarily need to run this command.
https://link.<region>.storjshare.io/s/<access key>/<object path>
To download content directly, use /raw/
in Linkshare URL ex: https://link.us1.storjshare.io/raw/ju34skavohcqezr6vlfgshg5nmjq/dwebdemo/isthataquestion.mp4
To view the object location map, use /s/
in Linkshare URL ex: https://link.us1.storjshare.io/s/ju34skavohcqezr6vlfgshg5nmjq/dwebdemo/isthataquestion.mp4
For more detail, visit the documentation on hosting a static website with the Uplink CLI.
./uplink.exe share --auth-service <auth service address> --dns <hostname> sj://<path>
uplink share --auth-service <auth service address> --dns <hostname> sj://<path>
uplink share --auth-service=https://auth.us1.storjshare.io --base-url=https://link.us1.storjshare.io --dns www sj://cakes/
=========== ACCESS RESTRICTIONS ==========================================================Download : AllowedUpload : DisallowedLists : AllowedDeletes : DisallowedNotBefore : No restrictionNotAfter : No restrictionPaths : sj://cakes/ (entire bucket)=========== SERIALIZED ACCESS WITH THE ABOVE RESTRICTIONS TO SHARE WITH OTHERS ===========Access : 12BncZWg9xc4GyXCDX73...========== CREDENTIALS ===================================================================Access Key ID: ju3ga56lfk7x...Secret Key : j2psszecoqtc...Endpoint : https://gateway.us1.storjshare.ioPublic Access: true=========== DNS INFO =====================================================================Remember to update the $ORIGIN with your domain name. You may also change the $TTL.$ORIGIN example.com.$TTL 3600www IN CNAME link.us1.storjshare.io.txt-www IN TXT storj-root:cakestxt-www IN TXT storj-access:ju3ga56lfk7x...
Use the generated DNS info to connect your domain name to your shared objects.