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

Port prereqs+launch logic to butler service #1642

Closed
27 of 30 tasks
fasterthanlime opened this issue Jan 28, 2018 · 2 comments
Closed
27 of 30 tasks

Port prereqs+launch logic to butler service #1642

fasterthanlime opened this issue Jan 28, 2018 · 2 comments

Comments

@fasterthanlime
Copy link
Collaborator

fasterthanlime commented Jan 28, 2018

Aaaaaction plan:

  • Have itch app pass installFolder, game, upload, verdict
  • Parse manifest if there's one
  • Handle prereqs
    • Have a single folder where all prereqs live, and keep them there (app specifies which folder that is)
    • Update the registry if we can (if we're online)
    • Download missing prereqs to single folder, write plan to temp directory
    • Fork ourselves elevated with plan (same as before)
    • Forward progress messages
    • Allow running the game anyway if prereqs fail (via modal)
  • If no candidates, re-configure
    • Have itch app cache the result
  • If multiple candidates, have user pick (via modal)
    • For manifest
    • For verdict
  • If still no candidates, just browse it
  • Handle API key
    • Make subkey request using passed credentials
    • Pass it to native apps
    • Pass it to HTML apps
  • Once we have a candidate, determine launch strategy (native, html, etc.)
    • For native, launch ourselves, let app know it's running (progress bar stops being indeterminate)
      • Working directory: dir of the executable path, if it's relative to the install folder - otherwise just the base install folder
      • Make temp directory, set environment variables
      • Setup sandbox if needed (might need modals for apt-get firejail, creating the user on windows, etc.)
      • Collect stdout/stderr, preferably with a ring buffer of some sort so the output isn't exceedingly large
      • If non-zero exit code, and game hasn't been running for more than 5s, report issue
      • Handle console properly
      • Handle .jar files
    • For all other types, let app know what it should do
  • Merge documentation for new platform type
fasterthanlime added a commit to itchio/butler that referenced this issue Feb 2, 2018
fasterthanlime added a commit that referenced this issue Feb 2, 2018
@fasterthanlime
Copy link
Collaborator Author

Now done in master.

@aaronfranke
Copy link

aaronfranke commented Feb 26, 2018

Good work, thanks for adding #1587! I'll close the issue once the fix arrives downstream to the build.

Don't forget about the documentation! Also, to improve readability, I would like to suggest moving the API key stuff to another page (and linking to it on the Manifests page). Not everyone shipping a manifest will need API keys, and shorter documentation pages are easier to read and scroll through.

For those who do wish to use API keys, you can include more information if there is a separate API key page. After reading it, I can't really tell what scoping is, how to use it, or why it matters. Furthermore, examples of Unity game integration would be nice.

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