Support ticket questions

I am looking at the Support Ticket menu item in 3.0, Customizations — Open OnDemand 3.0.0 documentation, since I think it’d be useful to provide this option to our users. I have a few questions about that.

First, how is the e-mail being sent? In the documentation, an example of Gmail smtp is provided, but, I would imagine one would need to provide username and password in the config file which is not ideal. In our case, authenticating to OOD (via CAS), the user is also authenticated to our University e-mail, so, I am wondering if we could somehow automatically send that e-mail via this route.

With an initial naive setup in ondemand.yml which looks like this:

    to: ""

I get an error from OOD after pushing the send button as:

There was an error processing your request: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate) 

Second, I think it’d be good to auto-fill the user’s e-mail address. We have a erb snippet for that in the submit.yml.erb already, which looks like this:

  emailcmd = '/uufs/ ' + ENV["USER"]
  emailaddr = %x[ #{emailcmd}]
  email: <%= emailaddr %>

So, I am wondering if I could do something similar, perhaps in the # /etc/ood/config/apps/dashboard/views/support_ticket/email/_email.text.erb? Or running the /etc/ood/config/ondemand.d/ondemand.yml through erb first?

Or, even better, knowing the user name, we could form the e-mail based on that (our user names are u0123456, and the corresponding e-mail is


Regarding how it’s sending email —

If you do provide an SMTP address it attempts to use localhost as it’s SMTP server. We (OSC) have all our machines configured as STMP relays to our actual relay server. To test or verify your web servers setup I’d suggest getting an ssh session on that machine and see if you can sendmail or run other tests to see if that server can successfully relay messages.

If it can’t then you can either set the webserver up so that it can relay messages or just configure OnDemand to use your actual relay server.

Regarding the email address —

This is likely the easiest for you. We don’t support it on our side because that’s not the case for us, our email addresses could be anything. And what’s more, finding the users email address generally requires some privilege that users don’t have. I.e., most sites don’t allow anyone to query LDAP or if they do what’s returned is not sensitive like the email address.

  email: <%= Etc.getlogin %>

Thanks Jeff. I’ll ask our admins about the SMTP relay.

As for the email address - do I need to rename the ondemand.yml into ondemand.yml.erb to get that ruby processed?

And how would I feed the “from” e-mail into the form field, e.g. as in:

    from: <%= Etc.getlogin %>
    to: ""
    - email
    - subject
    - attachments
    - description

I don’t think so.

I believe you have it already there. Though you don’t need the email field in the form if you’ve already hard coded the from section.

Hi, I have another question on the support ticket.

I noticed that one gets a link for support ticket from each interactive job tiles. That’s great, but, I am wondering if we could auto-populate the Session ID, or its URL or path in the subject or body of the ticket e-mail message. That would be quite useful.


I think if you add session_id to your form it’ll auto populate the session id. You may also want to provide session_description as it has a little more info than just the session id.

Hi guys,

Not sure if this is the right place to ask but here it goes. I’m trying to configure the Support ticket feature using the OOD Ansible Role, but I could not find any docs on how to use it. Tried using support_ticket object/dictionary but it’s not working.
Any suggestions? Maybe the answer is to open an Issue on Github?

Thanks in advance!

Yea I think that’s the best bet. Looks like we need to add support for it to the role.

Hi @jeff.ohrstrom,

Did a PR few minutes ago, hope it helps!

Thanks again! Cheers

Thanks! I got it and will merge it - there’s just some unrelated issues with the tests.

1 Like


To piggy back on this, is there a way to get the user’s email address from the authenticated session, by any chance?

For instance, when using OpenID Connect for authentication, the IDP can provide an email address as part of the OIDC claims. Is it possible to use that information here?

We’ve considered this and could add it in the future - we just don’t have support across all authentication methods. Though clearly OIDC could work here, we just haven’t gotten around to implementing it.

Hi @jeff.ohrstrom

Thanks for the reply!
I found this discussion which asked about pretty much the same thing.

One simple solution could maybe to allow passing a certain set of sysadmin-configurable environment variables between the front-end Apache authenticating instance and the nginx PUNs?

It would certainly be a valuable addition to the feature set, given that many authentication backend provide contextual information about authenticated users (email address, group membership…) that could be certainly be handy and useful in custom PUN applications.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.