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

Support modifying environment variables #4

Open
n0n0x opened this issue Jul 19, 2016 · 1 comment
Open

Support modifying environment variables #4

n0n0x opened this issue Jul 19, 2016 · 1 comment

Comments

@n0n0x
Copy link
Member

n0n0x commented Jul 19, 2016

12 factor apps like podcast api use a .env file, add a way to modify such files such as:

fab production set_env:ENV_VAR,ENV_VALUE

if the env exists, then replace if not, then append. http://docs.fabfile.org/en/1.11/api/contrib/files.html

Something like this should work:

if fabric.contrib.files.contains().failed:
    fabric.contrib.files.append()
else:
    fabric.contrib.files.sed()

maybe use if fabric.contrib.files.sed().failed: directly

@n0n0x
Copy link
Member Author

n0n0x commented Jul 22, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant