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

WIP - Packaging #514

Merged
merged 6 commits into from
Dec 7, 2017
Merged

WIP - Packaging #514

merged 6 commits into from
Dec 7, 2017

Conversation

victorb
Copy link
Member

@victorb victorb commented Nov 28, 2017

OSX build seems to work fine, ends up with a .dmg at least.

Linux fails on RPM builds.

Example artifacts: https://ci.ipfs.team/blue/organizations/jenkins/IPFS%20Shipyard%2Fstation/detail/packaging/5/artifacts/

Missing waiting for windows. Will continue with this


Close #508, close #20 and close #16.

@hacdias
Copy link
Member

hacdias commented Dec 1, 2017

I added some closes to your comment so the issues are closed when this gets merged 😄

@daviddias
Copy link
Member

@victorbjelkholm @hacdias what's missing to make this happen?

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

@diasdavid verifying that the osx build actually works. It successfully built but has not been verified by anyone yet.

Then getting the builds for linux and windows to produce artifacts, working on this atm.

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

Got all the builds to successfully turn into a package on all OSes. Left is to verify that they actually work. Also, would like to change the version from being the version set in package.json to the current commit instead.

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

8b3a6fc#diff-b9cfc7f2cdf78a7f4b91a753d10865a2L13 screwed me a bit after getting all the builds working and then doing a rebase from master. Fixed this and waiting for build to finish now. (btw, electron-forge does not have the most user-friendly errors, just crashes without any notices, when in reality the icon files were missing)

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

Ok, got a successful build of all OSes again.


~~~List of artifacts: https://ci.ipfs.team/blue/organizations/jenkins/IPFS%20Shipyard%2Fstation/detail/PR-514/17/artifacts~~~

~~~**Now need some help to test the resulting binaries! Please try them out on your favorite OS and leave feedback here if something is not working**~~~

~~~Direct download:~~~

- ~~~DMG for macOS: https://ci.ipfs.team/job/IPFS%20Shipyard/job/station/job/PR-514/17/artifact/out/make/IPFS%20Station-0.1.0.dmg~~~
- ~~~RPM for Red Hat et al: https://ci.ipfs.team/job/IPFS%20Shipyard/job/station/job/PR-514/17/artifact/out/make/ipfs-station-0.1.0.x86_64.rpm~~~
- ~~~DEB for Debian + Ubuntu: https://ci.ipfs.team/job/IPFS%20Shipyard/job/station/job/PR-514/17/artifact/out/make/ipfs-station_0.1.0_amd64.deb~~~
- ~~~EXE for Windows: https://ci.ipfs.team/job/IPFS%20Shipyard/job/station/job/PR-514/17/artifact/out/make/squirrel.windows/x64/IPFS%20Station-0.1.0%20Setup.exe~~~
- ~~~NUPKG for Windows (as well?): https://ci.ipfs.team/job/IPFS%20Shipyard/job/station/job/PR-514/17/artifact/out/make/squirrel.windows/x64/Station-0.1.0-full.nupkg~~~

Edit: success in building but packages were broken. Please see latest comment

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

.deb on Ubuntu 16.04.3 is acting weird and not working. After installing, it doesn't add anything to the dash menu or in $PATH, leading to not being able to open the application unless manually executing /usr/lib/ipfs-station/IPFS\ Station which /usr/bin/ipfs-station is supposed to be a symbolic link to, but it points to ../lib/ipfs-station/ipfs-station instead (notice the whitespace and mix lower/upper case).

When manually running the right executable, I get the following error:

$ /usr/lib/ipfs-station/IPFS\ Station
A JavaScript error occurred in the main process
Uncaught Exception:
Error: Cannot find module 'electron-compile'
    at Module._resolveFilename (module.js:470:15)
    at Function.Module._resolveFilename (/usr/lib/ipfs-station/resources/electron.asar/common/reset-search-paths.js:35:12)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/usr/lib/ipfs-station/resources/app/es6-shim.js:4:23)
    at Object.<anonymous> (/usr/lib/ipfs-station/resources/app/es6-shim.js:10:3)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)

So at least two things are not working when installing/packaging for .deb

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

Did a quick test on windows and getting the same error as on Ubuntu. Not sure what's wrong in the packaging process.

Edit: did test on osx as well and same issue.

@victorb
Copy link
Member Author

victorb commented Dec 5, 2017

Everything working OK on macOS now, more testing would be welcome though!

Ubuntu version is still acting up, now getting the following error:

non-zero exit code 1

            while running: /usr/lib/ipfs-station/resources/app/node_modules/go-ipfs-dep/go-ipfs/ipfs daemon


            internal/child_process.js:319
    throw errnoException(err, 'spawn');
    ^

Error: spawn EACCES
    at exports._errnoException (util.js:1050:11)
    at ChildProcess.spawn (internal/child_process.js:319:11)
    at exports.spawn (child_process.js:390:9)
    at module.exports (/usr/lib/ipfs-station/resources/app/node_modules/comandante/index.js:11:14)
    at Object.<anonymous> (/usr/lib/ipfs-station/resources/app/node_modules/subcomandante/subcom:23:13)
    at Object.<anonymous> (/usr/lib/ipfs-station/resources/app/node_modules/subcomandante/subcom:118:3)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)

Seems the ipfs binary from go-ipfs-dep is installed with only root having access to it, so the normal user cannot run it. If I run sudo chown user /usr/lib/ipfs-station/resources/app/node_modules/go-ipfs-dep/go-ipfs/ipfs and after try to run Station again, everything works OK.

Windows version pops up some weird code editor animation for a minute or something like that (probably want to replace with the IPFS logo or similar before proper release [also has the default winforms icon in the task bar]) which then just disappears without any notice, and now station is installed? Anyways, once installed, it doesn't seem to transition from the loading screen to the screen where I can actually see my node.

package.json Outdated
@@ -11,6 +11,7 @@
"file-extension": "^4.0.0",
"ipfs-api": "^17.1.3",
"ipfs-geoip": "^2.3.0",
"ipfs-logo": "^0.2.0",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should not need this anymore. Make sure to rebase master onto this branch @victorbjelkholm

@hacdias
Copy link
Member

hacdias commented Dec 5, 2017

The installer above works for me on windows, but the icons are broken. Please rebase into master. I also have to update the icons on package.json since they're still using ipfs-logo.

@machawk1
Copy link
Contributor

machawk1 commented Dec 5, 2017

I poked around the macOS version linked from the dmg above. Based on my limited experience with running it from Terminal, the behavior appears consistent.

Is there a plan to use a station-specific icon for the .app or to retain the IPFS cube?

@hacdias
Copy link
Member

hacdias commented Dec 5, 2017

Windows version pops up some weird code editor animation for a minute or something like that (probably want to replace with the IPFS logo or similar before proper release [also has the default winforms icon in the task bar]) which then just disappears without any notice, and now station is installed? Anyways, once installed, it doesn't seem to transition from the loading screen to the screen where I can actually see my node.

ElectronForge uses Squirrel installers for windows whose slogan is "Squirrel: It's like ClickOnce but Works™". I think you can take your conclusions about "disappears without any notice" 😄 We could replace the animation by some image saying "IPFS Station is being installed" and then the logo of IPFS.

I think it is effective to install and easy to use. The only problem I can found is that I don't know if it is possible to remove the .ipfs folder when uninstalling but I think it might be possible.

@daviddias
Copy link
Member

@hacdias let's avoid using the word cosmos as it might confuse users with another P2P Network. Try perhaps "Becoming InterPlanetary"

@victorb
Copy link
Member Author

victorb commented Dec 6, 2017

Jenkins is now also setting the status of the commit, where you'll always be able to find the built binaries for the three platforms.

image

@hacdias
Copy link
Member

hacdias commented Dec 6, 2017

@victorbjelkholm jenkins says the last build was 7 days ago. Am I looking in the wrong place?

@victorb
Copy link
Member Author

victorb commented Dec 6, 2017

@hacdias yes, that's the wrong place. Correct latest build associated with this PR is in the status check for easy access. Just click on "Show all checks", then click on "Details" to the right of the "continuous-integration/jenkins/pr-merge" job. You should be taken to https://ci.ipfs.team/blue/organizations/jenkins/IPFS%20Shipyard%2Fstation/detail/PR-514/22/pipeline then which is the latest job. Shows up as "3 hours ago" for me.

@hacdias
Copy link
Member

hacdias commented Dec 6, 2017

Strangely, it is building binaries with ~120MB for windows with the old version.

image

@hacdias
Copy link
Member

hacdias commented Dec 6, 2017

We should also take a look at this since Windows executables must be signed in order not to blocked by antivirus and/or windows firewall.

@hacdias
Copy link
Member

hacdias commented Dec 6, 2017

@victorbjelkholm I think the installers are not working since it is packaging the old version somehow.

@daviddias
Copy link
Member

What about merging this PR and working from master? So that you are sure that you are working in the latest

@hacdias
Copy link
Member

hacdias commented Dec 7, 2017

Yeah, I agree @diasdavid

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants