Closed dotNomad closed 1 month ago
I noticed this failed on the config check in the ui tests. I have a fix locally, let me know if you want me to push it up to your branch.
I noticed this failed on the config check in the ui tests. I have a fix locally, let me know if you want me to push it up to your branch.
No that is alright. This is very much a draft to prompt discussion right now. If we decide to go down this path we can update the tests.
This is a rough draft of how we could include the posit files when creating new deployments.
Intent
Resolves #2370
Type of Change
Approach
While exploring how we could do this I implemented a really simple version of this.
When creating a new deployment we first create a Configuration, passing the name we would like it to have, then create a Deployment, also with a name passed.
The configuration is passed from the inspection API which doesn't include the
.posit
files sense they aren't created at that point.We could insert the configuration file into the files array before sending it up to be created, but the deployment still hasn't been made.
To avoid changing the APIs I did the simplest thing, included two more API calls to include the files after they are created.
We may not want to go with this method, and instead move some of this logic into the API endpoints.
Additionally this PR does not mess with the "Select Active Configuration for Deployment" feature which ideally would include the new deployment in the configuration file. It is unclear how that should behave if a Configuration by multiple Deployments.