geeklearningio / gl-vsts-tasks-yarn

Yarn Package Manager Visual Studio Team Services Build and Release Management extensions

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Yarn tasks fails due to DNS issue? `getaddrinfo ENOTFOUND publicblobs.geeklearning.io publicblobs.geeklearning.io:443`

dotansimha opened this issue · comments

Since a few hours ago, it seems like publicblobs.geeklearning.io is down, leading to a failure when using the VSTS task:

Starting: Use Yarn (1.x)
==============================================================================
Task         : Yarn Tool Installer
Description  : Installs a version of Yarn
Version      : 3.0.1999
Author       : Geek Learning
Help         : [More Information](https://github.com/geeklearningio/gl-vsts-tasks-yarn/wiki/Yarn) (Version 3.0.1999)
==============================================================================
##[warning]This task uses Node 6 execution handler, which will be deprecated soon. If you are the developer of the task - please consider the migration guideline to Node 10 handler - https://aka.ms/migrateTaskNode10. If you are the user - feel free to reach out to the owners of this task to proceed on migration.
##[error]getaddrinfo ENOTFOUND publicblobs.geeklearning.io publicblobs.geeklearning.io:443
Finishing: Use Yarn (1.x)

@sandorfr any idea how this can be resolved?

Having the same issue as well

From a WHOIS search, it looks like the domain name has expired today (November 23, 2021). That's why the fetch is failing...

Seems like latest ubuntu image of Azure DevOps supports Yarn as built-in so I'm not sure if this task is needed...

Confirmed comment by @dotansimha - Just ran my build task without the installer and subsequent tasks using yarn were able to execute

Having exactly the same issue, my devops task fails :
image

Seems like latest ubuntu image of Azure DevOps supports Yarn as built-in so I'm not sure if this task is needed...

Yarn 1.22.17 is also built-in on windows-2016, windows-2019 and windows-2022 build agents as well.

I unchecked the "Always download the latest matching version" in my Use Yarn task and the builds are working again. Once this is fixed, I'll go back to downloading Yarn.
image

confirmed @norlandoPDDS was correct. Just pulled out task: YarnInstaller@3 and everything built fine.

Confirmed, just uncheck "Always download the lastest matchig version" and its works like charm.
Thanks @RPbarfield

The value of this tasks was in being able to stay up to date with the latest version, though. Seems a more robust way would be for it to check https://registry.npmjs.org/yarn.

The error has already been solved?

I'm actually wondering if there is any value to this tool installer task anymore since yarn no supports installs via npm, and azure pipelines now supports chocolatey. This give two builtin way to install yarn without relying on this 3rd party (as neither official yarn or azur pipelines).

Since I have the attention of some fellow users of this, what are your thoughts?

To clarify my thoughts, yarn 1.x is available in the standard agent image. When it comes to yarn 2.x and ulterior, they can be enabled directly via corepack.

The following would be a an example that does everything without this extension.

  - task: NodeTool@0
    inputs:
      versionSpec: '16.13.x'
  - task: Bash@3
    displayName: Yarn enable
    inputs:
      targetType: 'inline'
      script: |
        corepack enable
        corepack prepare yarn@3.1.1 --activate
  - task: Cache@2
    inputs:
      key: '"yarn" | "$(Agent.OS)" | yarn.lock'
      restoreKeys: |
        yarn | "$(Agent.OS)"
        yarn
      path: $(YARN_CACHE_FOLDER)
    displayName: Cache Yarn packages
  - task: Bash@3
    displayName: Yarn
    inputs:
      targetType: 'inline'
      script: |
        yarn --frozen-lockfile
  - task: Bash@3
    displayName: Yarn build
    inputs:
      targetType: 'inline'
      script: |
        yarn build

If package feed authentication is needed, npm authenticate should do the job.