Skip to content

NodeJS SDK: decide how to package #3096

Closed

Description

@sipsma

Two approaches:

  1. Monorepo - we keep it in cloak. This may mean we need to move its package.json to the root of the repo (not sure though, this is a requirement when specifying a dep on it using git+ssh, but maybe its not needed if we move to use npm publish)
  2. Own-repo - we move it to something like dagger/cloak-nodejs-sdk

cc @slumbering @crjm

Activity

  1. slumbering commented on Aug 25, 2022

    @slumbering
    Contributor

    I'm a monorepo guy, but i also feel that having every sdk in their own repo would make more sense as there are projects in their own right.

    However does it mean that we'll need to "keep an eye" on every repo if users contribute (open issues or PR) ?
    How about users who want also to contribute by creating a new sdk ?

  2. crjm commented on Aug 25, 2022

    @crjm
    Contributor

    I like option no. 1. After reconsidering and looking at a few repos, I can see that it's really straightforward to have different npm packages in a same repo.
    Here is Next.js with each package in a different folder.
    You can see that they have different packages for different languages (Rust, JS) and they are scoped to that directory.
    The package.json in create-next-app packages seems straightforward:

      "repository": {
        "type": "git",
        "url": "https://github.com/vercel/next.js",
        "directory": "packages/create-next-app"
      },
    
  3. slumbering commented on Aug 29, 2022

    @slumbering
    Contributor

    We've get an interesting user feedback during a Cloak community call today. It was about how a big German car company is handling its repo with josh project which basically combine the advantages of a monorepo with those of multirepo setups. More to read here: https://github.com/josh-project/josh
    cc @sipsma @aluzzardi

  4. sipsma commented on Sep 2, 2022

    @sipsma
    ContributorAuthor

    Seems like everyone likes monorepos (me too), so I ended up finding a way to make that work while still being able to keep the nodejs sdk in it's own dir. The commit with that change is here: dagger/cloak@6aaa827

    Gonna close this issue for now as it seems like this should be the approach going forward until proven otherwise.

  5. added this to the Cloak GA milestone on Sep 16, 2022
  6. transferred this issue fromdagger/cloakon Sep 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions