package service const ( RELPATH_PLUGINS = "/plugins" RELPATH_PROFILES = "/profiles" RELPATH_DATA = "/data" RELPATH_METADATA = "/.makeshift" RELPATH_HELP = RELPATH_DATA + "/index.html" RELPATH_PROFILE = RELPATH_PROFILES + "/default.json" PATH_CONFIG = "$HOME/.config/makeshift/config.yaml" DEFAULT_TIMEOUT_IN_SECS = 60 DEFAULT_PLUGINS_MAX_COUNT = 32 DEFAULT_PROFILES_MAX_COUNT = 256 FILE_METADATA = `` FILE_HOME_PAGE = `

# setup environment variables
export MAKESHIFT_HOST={{ makeshift.host }}
export MAKESHIFT_PATH={{ makeshift.path }}
export MAKESHIFT_SERVER_ROOT={{ makeshift.server.root }}

# start the service
makeshift serve --root $HOME/apps/makeshift/server --init

# download a file or directory (as archive)
makeshift download
makeshift download --host http://localhost:5050 --path help.txt

# download files with rendering using plugins
makeshift download --plugins smd,jinja2 --profile compute
curl $MAKESHIFT_HOST/download/help.txt?plugins=smd,jinja2

# upload a file or directory (recursively)
makeshift upload
makeshift upload --host http://localhost:5050 --path help.txt

# list the files in a directory
makeshift list --path help.txt
makeshift list --host http://localhost:5050 --path help.txt
curl http://localhost:5050/list/test

` FILE_DEFAULT_PROFILE = ` { "id": "default", "description": "Makeshift default profile", "data": { "makeshift": { "host": "localhost", "path": "/test", "server": { "root": "/test" } } } } ` ) // makeshift.host: https://localhost:5050 // makeshift.path: test // makeshift.server.root: $HOME/apps/makeshift