-
Notifications
You must be signed in to change notification settings - Fork 18
Conversation
I love the idea, but I'm unsure how good or bad of a decision it is to add python3 as a requirement to Den. |
Given that den is using docker, why not simply use docker to run the python command? Or rewrite it to use |
@LeeSaferite The idea was to use tools already available on the Mac without adding external dependencies, as well as not having to download another docker container to parse JSON. I'll give some alternatives a try (jq docker, python docker, manually parsing via bash). @navarr Python should already be available on MacOS. I have Xcode tools installed so Python3 is also available (though the syntax only changes a little bit between 2 and 3). But as Lee pointed out, I'll research alternatives. |
It is, and while Mac is the primary target at SO, Den supports Linux and Windows as well. |
I'll have a fix for this later this evening. I think i just need to step up my Golang template fu and I can completely remove the Python scripts. |
@navarr Removed python as dependency, also changed the output to add more information about the project (Traefik domain). |
This doesn't appear to be working for me. First off, versions. I'm running off your latest commit to this branch.
Is what I try to get running it outside of Any additional things I can do to get more information for you? |
@navarr Submitted a fix. I use simple 3-letter environment names, so my "prefix" is always shorter than the den core container names (traefik, mailhog, etc.). The issue was in longer names (e.g. znd-magento2) that prefix was longer than those core container names, causing the out of bounds error. I added a quick length check so only container names that are longer than the prefix are checked (which should be all the environment-specific containers). There is still room for improvement (e.g. what if I specify the container name in a custom warden-env.yml file), but that adds to the complexity of this, and BASH is a limiting language (in some ways). |
Great idea, but 2 things I would improve:
|
@ihor-sviziev Thanks for the comment! I've gone ahead and resolved improvement 2. I do think improvement 1 might be fairly difficult. One reason I like this command is because I'll commonly want to know which environments I have running so I can shut them down, so it remains useful to me with or without improvement 1. |
@ihor-sviziev Yeah, I was thinking about that. Initially I was going to say during the |
@bap14 Honestly I'm not a fan of that either. Far too many ways that it can get out-of-sync. |
Ported in from swiftotter#94 Co-authored-by: Brett Patterson <[email protected]>
Adds a new status command showing the current projects that are running and Den's Traefik instance is connected to.