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

Multiple Environment Support #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Multiple Environment Support #2

wants to merge 1 commit into from

Conversation

shapi78
Copy link

@shapi78 shapi78 commented Aug 8, 2018

Adding Environment variable
Environment variable to appear on mail sent to client which will distinguish between environments

Adding to subject:
OpenVPN Configuration for us-east-2_prod environment
And file attached will be -.ovpn

@shapi78 shapi78 requested a review from antgel August 8, 2018 10:32
@antgel
Copy link

antgel commented Sep 3, 2018

@alvagante This is the one I was talking about for review and merge, thanks. :)

@@ -13,7 +13,9 @@ def send_mail (
file_name,
receiver,
sender,
envirnmnt,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is indentation correct here?

@@ -36,6 +38,7 @@ def send_mail (

# open the file to be sent
filename = os.path.basename(file_name)
attachment_name = environment + "-" + filename

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indentation?

@@ -216,6 +216,7 @@
Hash $setenv_safe = {},
String $up = '',
String $down = '',
String $environment = 'prod',

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Better not to use local class variables called $environment, as they might create confusion with Puppet's interla variable $environment .
Use $env or something similar, here and in line 325.
Anyway, current code should work the same

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

Successfully merging this pull request may close these issues.

3 participants