Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 'env' subcommand to docktie_cli #33

Closed
casimpania opened this issue May 6, 2022 · 1 comment
Closed

Add 'env' subcommand to docktie_cli #33

casimpania opened this issue May 6, 2022 · 1 comment
Assignees
Labels
enhancement New feature or request PRIORITY_LOW
Projects
Milestone

Comments

@casimpania
Copy link

casimpania commented May 6, 2022

Idea is that it will show the exported environment variables that starts with DOCKTIE or PROJECT

(docktie > cooltool) ~$ env|grep "^PROJECT\|^DOCKTIE"|sort

where:

  • DOCKTIE - are for platform variables
  • PROJECT - except for $PROJECT_ROOTDIR, these are mostly defined in respective conf/*_env file.

So, this would involve changes to init.sh as well to auto-detect all declared PROJECT_ (except for PROJECT_NAME).
This is useful for things like shortcuts to BACKEND and FRONTEND or PARSER directories when working from command line.

Parsing for env would be something like this:

(docktie > cooltool) ~$ grep -v "^#\|^$\|^PROJECT_" env.sample
DOCKER_CONTAINER_PREFIX=example
AUTOSTART_PROJECT=0
DOCKTIE_SERVICES_TO_START=""
@casimpania casimpania added the enhancement New feature or request label May 6, 2022
@casimpania casimpania added this to the v0.1.2 milestone May 6, 2022
@casimpania casimpania added this to To do in v0.1.x May 6, 2022
@casimpania casimpania moved this from To do to In progress in v0.1.x May 6, 2022
casimpania pushed a commit that referenced this issue May 6, 2022
casimpania pushed a commit that referenced this issue May 6, 2022
@casimpania casimpania moved this from In progress to Done in v0.1.x May 6, 2022
@casimpania casimpania added documentation Improvements or additions to documentation PRIORITY_MEDIUM labels May 6, 2022
@casimpania casimpania moved this from Done to In progress in v0.1.x May 6, 2022
@casimpania
Copy link
Author

Oops, didn't notice that output of docktie_cli env and `env|grep "^DOCKTIE|^PROJECT" are different.
Add to that PROJECT_ROOTDIR in docktie_cli is that of docktie.

However, the environment variables as seen by "env" are what's important. Lowering priority to LOW

@casimpania casimpania reopened this May 6, 2022
@casimpania casimpania added PRIORITY_LOW and removed PRIORITY_MEDIUM documentation Improvements or additions to documentation labels May 6, 2022
@casimpania casimpania moved this from In progress to Done in v0.1.x May 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request PRIORITY_LOW
Projects
Development

No branches or pull requests

2 participants