Thanks @zodern and its great to have a reply from creator himself. I am able to now upload image the way but my only concern is I am not able to access it from the url generated and then I deploy it again considering the fact that the files would be accessible in the next build. But got this
The command '/bin/sh -c cd /built_app/programs/server && npm install --unsafe-perm' returned a non-zero code: 1
------------------------------------STDOUT------------------------------------
s_cflags=',
gyp verb cli '--libsass_ldflags=',
gyp verb cli '--libsass_library=' ]
gyp info using node-gyp@3.6.1
gyp info using node@8.4.0 | linux | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` succeeded python2 /usr/bin/python2
gyp verb check python version `/usr/bin/python2 -c "import platform; print(platform.python_version());"` returned: "2.7.9\n"
gyp verb get node dir no --target version specified, falling back to host node version: 8.4.0
gyp verb command install [ '8.4.0' ]
gyp verb install input version string "8.4.0"
gyp verb install installing version: 8.4.0
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp verb install version not already installed, continuing with install 8.4.0
gyp verb ensuring nodedir is created /root/.node-gyp/8.4.0
gyp verb created nodedir /root/.node-gyp
gyp http GET https://nodejs.org/download/release/v8.4.0/node-v8.4.0-headers.tar.gz
gyp WARN install got an error, rolling back install
gyp verb command remove [ '8.4.0' ]
gyp verb remove using node-gyp dir: /root/.node-gyp
gyp verb remove removing target version: 8.4.0
gyp verb remove removing development files for version: 8.4.0
gyp ERR! configure error
gyp ERR! stack Error: This is most likely not a problem with node-gyp or the package itself and
gyp ERR! stack is related to network connectivity. In most cases you are behind a proxy or have bad
gyp ERR! stack network settings.
gyp ERR! stack at Request.<anonymous> (/built_app/programs/server/npm/node_modules/meteor/materialize_materialize/node_modules/node-gyp/lib/install.js:193:21)
gyp ERR! stack at emitOne (events.js:115:13)
gyp ERR! stack at Request.emit (events.js:210:7)
gyp ERR! stack at Request.onRequestError (/built_app/programs/server/npm/node_modules/meteor/materialize_materialize/node_modules/request/request.js:867:8)
gyp ERR! stack at emitOne (events.js:115:13)
gyp ERR! stack at ClientRequest.emit (events.js:210:7)
gyp ERR! stack at TLSSocket.socketErrorListener (_http_client.js:401:9)
gyp ERR! stack at emitOne (events.js:115:13)
gyp ERR! stack at TLSSocket.emit (events.js:210:7)
gyp ERR! stack at emitErrorNT (internal/streams/destroy.js:64:8)
gyp ERR! System Linux 4.4.0-1060-aws
gyp ERR! command "/opt/nodejs/bin/node" "/built_app/programs/server/npm/node_modules/meteor/materialize_materialize/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /built_app/programs/server/npm/node_modules/meteor/materialize_materialize/node_modules/node-sass
gyp ERR! node -v v8.4.0
gyp ERR! node-gyp -v v3.6.1
gyp ERR! not ok
Build failed with error code: 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.5.2 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.5.2 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-06-30T15_19_41_742Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! meteor-dev-bundle@ install: `node npm-rebuild.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the meteor-dev-bundle@ install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-06-30T15_19_41_963Z-debug.lo
While deploying it again. Would be great if you can provide the solution for this.