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

Login fail after upgrade to v3.0.0 (please specify JIRA_BAS_URL) #36

Closed
cedmart1decath opened this issue Nov 23, 2022 · 3 comments
Closed

Comments

@cedmart1decath
Copy link

Run atlassian/gajira-login@v3
Error: Please specify JIRA_BASE_URL env
at exec (/home/runner/work/_actions/atlassian/gajira-login/v3/dist/index.js:29722:43)
at /home/runner/work/_actions/atlassian/gajira-login/v3/dist/index.js:29769:1
at /home/runner/work/_actions/atlassian/gajira-login/v3/dist/index.js:29771:3
at Object. (/home/runner/work/_actions/atlassian/gajira-login/v3/dist/index.js:29774:12)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
at node:internal/main/run_main_module:17:47

Same yaml conf works in another action (it waa working when using v2)

steps:
  - name: Jira Login
    uses: atlassian/gajira-login@v3 # same with v3.0.0
    env:
      JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }}
      JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}
      JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
@mboudreau
Copy link
Contributor

We haven't changed any code around the validation of the environment variables, so this is surprising. The logic is pretty simplistic:

if (!process.env.JIRA_BASE_URL) throw new Error('Please specify JIRA_BASE_URL env')
if (!process.env.JIRA_API_TOKEN) throw new Error('Please specify JIRA_API_TOKEN env')
if (!process.env.JIRA_USER_EMAIL) throw new Error('Please specify JIRA_USER_EMAIL env')

Essentially, if it's defined and not an empty string, it should pass. Can you try setting the version to v2.0.0 (the previous version) to see if it works then? Our action run seems to work fine using the latest.

@cedmart1decath
Copy link
Author

Damn not working with 2.0 either might be something wrong with my yaml then ! weird though because at some point it was working. I am closing this issue then.

@cedmart1decath
Copy link
Author

cedmart1decath commented Nov 24, 2022

After further investigation I found out that the problem come from the fact that dependabot (forgot to mention this) does not have access to secrets !

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

2 participants