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

OpenVPN: custom mail text #6193

Closed
gsanchietti opened this issue Jun 5, 2020 · 7 comments
Closed

OpenVPN: custom mail text #6193

gsanchietti opened this issue Jun 5, 2020 · 7 comments
Labels
verified All test cases were verified successfully

Comments

@gsanchietti
Copy link
Member

The OpenVPN UI allows to send the client configuration directly to users by mail.
Currently, the text of the mail is fixed but some users may require changing it.

Proposed solution

Add a configuration file to allow changing the mail text.

@gsanchietti gsanchietti changed the title OpenPN: custom mail text OpenVPN: custom mail text Jun 5, 2020
gsanchietti added a commit to NethServer/nethserver-vpn-ui that referenced this issue Jun 5, 2020
The new '/etc/nethserver/openvpn-mail.cfg' configuration file can be
used to customize (or just translate) the mail sent by the UI

NethServer/dev#6193
@nethbot
Copy link
Member

nethbot commented Jun 5, 2020

in 7.8.2003/testing:

@gsanchietti
Copy link
Member Author

Test case 1

  • Configure a machine with at lease one OpenVPN user
  • Send the configuration by mail from the UI
  • Upgrade the machine
  • Re-send the configuration by mail from the UI, verify the text of the mail is unchanged

Test case 2

  • Create the /etc/nethserver/openvpn-mail.cfg and put some text on it
  • Send the configuration by mail from the UI, verify the mail contains the new text

QA note: more about configuration file format available inside the README

@gsanchietti gsanchietti added the testing Packages are available from testing repositories label Jun 5, 2020
@cotosso
Copy link

cotosso commented Jun 5, 2020

Test case 1: ok
Test case 2: it seems to be ok, but I also tried to use the $name variable in the email text.
If I use the $name variable more than once in the text it's expanded only the first time, e.g.

mio $name
mio $name
mio $name

becomes in the email text

mio ACCOUNTNAME
mio $name
mio $name

is that normal?

@nethbot
Copy link
Member

nethbot commented Jun 8, 2020

in 7.8.2003/testing:

@gsanchietti
Copy link
Member Author

is that normal?

Yes, the code was implemented to fit current usage scenario.
Still, I made a modification to fit your expectations.

Could you please check again @cotosso ?

@cotosso
Copy link

cotosso commented Jun 8, 2020

I just checked and now it works as expected

@cotosso cotosso added verified All test cases were verified successfully and removed testing Packages are available from testing repositories labels Jun 8, 2020
@nethbot
Copy link
Member

nethbot commented Jun 8, 2020

in 7.8.2003/updates:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
verified All test cases were verified successfully
Projects
None yet
Development

No branches or pull requests

3 participants