When running `DEBUG="*" graphcool deploy` I see t...
# prisma-whats-new
s
When running
DEBUG="*" graphcool deploy
I see this
Copy code
deploy bundling +588ms
  bundler /home/sindre/git/nvbf/pepper/.build/build.zip
Bundling functions...  bundler added files [ '.babelrc',
  '.git/',
  '.git/index',
  ....
 'node_modules/.bin/',
  'node_modules/@storybook/',
  ....
  .storybook/
  .next/
... 190614 more items ]
This seems like a lot of files that graphcool should not care about! are there any ignore file I can add them to? or a ignore directive in the graphcool.yml file?
n
please put the graphcool service definition in its own folder
node_modules
of the current directory will be bundled before deploying
s
thx!
So to isolate what the resolver functions uses It is best practice to separate the service into a folder and create a
package.json
with the dependencies that is needed by the resolver functions? (to not upload unneeded libs)
n
that has nothing to do with resolver functions specifically
everytime you
graphcool deploy
, the
node_modules
folder is bundled, zipped and deployed 😛
s
guess there is something I miss here.. why is that done?
n
to resolve dependencies defined in functions (any functions, not only resolvers)
s
Ok, but to get the deploy to be much faster for large repos, it would be recommended to isolate the graphcool functions into a folder with it's own package.json with the graphcool dependcies, so you only deploy what you need ?
I checked now with the
time
command. I reduced the deploy from right over 7 min to right under 5 sek by doing this! If things are on top level It takes all the dot folders also, including .git. For me this is a obiuoes performance enchantment To file and issue on this is the
graphcool/framework
the right place?
n
yes, it is 🙂 thanks!