polar
polar copied to clipboard
Feat/persistent-docker-network
-NewNetwork now has an input to create/attach to an external docker network -NetworkActions now has a modal for the user to create/attach/clear to an external docker network.
Closes #(issue number goes here) https://github.com/jamaljsr/polar/issues/525
Description
Allows for polar to attach or create an external docker network.
Steps to Test
-
Create a new network.
-
Fill out the Docker External Network field
-
Check the docker-compose file or
docker network ls -
In a current network, go to docker options in the hamburger menu of NetworkActions.
-
In the modal, name your docker network. Hit okay
-
Check the docker-compose file or
docker network ls.
A status icon is also visible.
ANd just a heads up, this is a prototype, I dont have any tests or anything written yet.
Apologies for the delay in reviewing this. I've been traveling. I'll test this out and provide feedback by the end of the week. Thanks for tackling this issue.
Hey, @jamaljsr could I get a quick review on its current roughed in ui? I'm worried it might be going out of scope.
Questions: Should new network have the ability to create or attach a docker network. While remaining unattached and having used this feature already on my current project, this is something I like.
Is this badge a good idea?
Docker options, I think this is appropriate place for them while providing a place extend docker features.
Hey @amovfx thanks for the updates. I'll take a look at this in the next few days.
I have tested the functionality. Great job querying for the list of existing networks. That's a great touch 👌
I do have some suggestions for improvement:
- When creating a new network, we should hide the external network field under a collapsible Advanced Options section. Since 99% of users will never use this, I don't think it should be front and center.
- I'm not a fan of the badge next to the network name. These messages would look better as alerts on the canvas, similar to this
- Adding the Docker Options item to the dropdown menu is great placement. I would just suggest to put it above the Delete option. It's better UX to have delete at the bottom.
- I created a new Polar network and specified an existing docker network. Afterwards, I went to the Docker Options modal but the network I chose was not pre-filled in the dropdown.
Awesome feedback. Will make these adjustments asap. Thanks.
Made these changes if you want to give them a look over and give the thumbs up. I'm going start doing a code review and a git squash. This one got pretty hairy so I'll probably need quite a bit of feedback on the review to bring it up to spec.
Hey @jamaljsr, Looking forward to your review.
I think this is the start of docker functionality. I have a couple branches of this PR to prototype some behavior that is helping my project that is interacting with docker more. Right now docker service actions are being called from the network store. This has me wondering if a store/model/docker.ts is going to be required.
Hi @amovfx do you plan on continuing to work on this PR?