question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Problem building on snapcraft.io due to DNS problem

See original GitHub issue

Issue Details

  • Electron Packager Version:
    • Latest?
  • Electron Version:
    • ^6.0.6
  • Operating System:
    • Ubuntu 18.04 amd64

Expected Behavior

Can build an electron-based kiosk snap on build.snapcraft.io using this tutorial.

Actual Behavior

Output of build:

[15/Nov/2019:12:06:34 +0000] "CONNECT registry.npmjs.org:443 HTTP/1.1" 200 6237 "install electron-packager" "npm/3.5.2 node/v8.10.0 linux arm"
[15/Nov/2019:12:06:34 +0000] "CONNECT registry.npmjs.org:443 HTTP/1.1" 200 11802 "install electron-packager" "npm/3.5.2 node/v8.10.0 linux arm"
[15/Nov/2019:12:06:35 +0000] "CONNECT registry.npmjs.org:443 HTTP/1.1" 200 7442 "install electron-packager" "npm/3.5.2 node/v8.10.0 linux arm"

> core-js@3.4.1 postinstall /build/webian-shell-kiosk/parts/webian-shell-kiosk/build/node_modules/core-js
> node postinstall || echo "ignore"

shell-kiosk@0.0.1 /build/webian-shell-kiosk/parts/webian-shell-kiosk/build
├─┬ electron@6.1.4
│ └─┬ electron-download@4.1.1
│   └─┬ debug@3.2.6 
│     └── ms@2.1.2 
└── electron-packager@14.1.0  extraneous

npm WARN shell-kiosk@0.0.1 No repository field.
getaddrinfo ENOTFOUND github.com github.com:443
Failed to run 'override-build': Exit code was 1.
Build failed
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/lpbuildd/target/build_snap.py", line 266, in run
    self.build()
  File "/usr/lib/python2.7/dist-packages/lpbuildd/target/build_snap.py", line 255, in build
    env=env)
  File "/usr/lib/python2.7/dist-packages/lpbuildd/target/build_snap.py", line 102, in run_build_command
    return self.backend.run(args, env=full_env, **kwargs)
  File "/usr/lib/python2.7/dist-packages/lpbuildd/target/lxd.py", line 502, in run
    subprocess.check_call(cmd, **kwargs)
  File "/usr/lib/python2.7/subprocess.py", line 541, in check_call
    raise CalledProcessError(retcode, cmd)
CalledProcessError: Command '['lxc', 'exec', 'lp-bionic-armhf', '--env', 'LANG=C.UTF-8', '--env', 'SHELL=/bin/sh', '--env', 'SNAPCRAFT_BUILD_INFO=1', '--env', 'SNAPCRAFT_IMAGE_INFO={"build-request-id": "lp-52608244", "build-request-timestamp": "2019-11-15T11:53:32Z", "build_url": "https://launchpad.net/~build.snapcraft.io/+snap/f2b382584d2db83cf919b0d75a474457/+build/734877"}', '--env', 'SNAPCRAFT_BUILD_ENVIRONMENT=host', '--env', 'http_proxy=http://10.10.10.1:8222/', '--env', 'https_proxy=http://10.10.10.1:8222/', '--env', 'GIT_PROXY_COMMAND=/usr/local/bin/snap-git-proxy', '--', '/bin/sh', '-c', 'cd /build/webian-shell-kiosk && linux32 snapcraft']' returned non-zero exit status 2
Revoking proxy token...
RUN: /usr/share/launchpad-buildd/bin/in-target scan-for-processes --backend=lxd --series=bionic --arch=armhf SNAPBUILD-734877
Scanning for processes to kill in build SNAPBUILD-734877

To Reproduce

Follow this tutorial.

Additional Information

I’m having a problem building two projects (shell and shell-kiosk) where I followed the same process as the tutorial linked to above. I think I’ve narrowed the problem down to electron-packager because the example in the tutorial no longer builds successfully on build.snapcraft.io where it did before.

My assumption is that something has changed in electron-packager which is causing the build to fail. I am able to get the build to work locally by changing the line:

cp -v -R ./webian-shell-kiosk-linux-$ARCH $SNAPCRAFT_PART_INSTALL/webian-shell-kiosk

to

cp -v -R /root/parts/webian-shell-kiosk/build/shell-kiosk-linux-$ARCH $SNAPCRAFT_PART_INSTALL/webian-shell-kiosk

but with this change the build still fails on the snapcraft build server with the same error as before.

Has there been some change to where the command:

electron-packager . --overwrite --platform=linux --arch=$ARCH --output=release-build --prune=true

will output to?

For more information, see my post on the Snapcraft forums.

Apologies if this has nothing to do with electron-packager and I’m barking up the wrong tree.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
maleptcommented, Nov 20, 2019

As of Electron Packager 14.1.1, proxy support is always enabled when using the CLI (#1077).

0reactions
cjwatsoncommented, Nov 21, 2019

@malept Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to modify name resolution parameters from a snap?
I am trying to enable the snap of a VPN client (openfortivpn) to modify name resolution parameters (DNS servers, domain search list).
Read more >
How do I fix my connection to api.snapcraft.io - Ask Ubuntu
I would like to fix this before updating. I can find similar problems described online, but they all seem to be caused by...
Read more >
Snaps not working : r/Ubuntu - Reddit
"lookup api.snapcraft.io no such host" sounds like you have an Internet connection problem - possibly a DNS problem.
Read more >
Domain Name Service (DNS) | Ubuntu
A very useful package for testing and troubleshooting DNS issues is the dnsutils package ... Now that the zone is setup and resolving...
Read more >
Horizon Cloud on Microsoft Azure Deployments - VMware Docs
Brief Points about Host Names, DNS Host Names, and Relationship to ... Due to a known issue that existed when the welcome email...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found