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

osxSign is not supported until Electron Packager 8.6.0 #162

Closed
3 tasks done
Guro opened this issue Mar 7, 2017 · 10 comments
Closed
3 tasks done

osxSign is not supported until Electron Packager 8.6.0 #162

Guro opened this issue Mar 7, 2017 · 10 comments

Comments

@Guro
Copy link

Guro commented Mar 7, 2017

  • I have read the contribution documentation for this project.
  • I agree to follow the code of conduct that this project follows, as appropriate.
  • I have searched the issue tracker for an issue that matches the one I want to file, without success.

Please describe your issue:
i'm trying to sign my app on mac, as electron-packager documentation says setting osxSign:true should sign app after packaging
here is my config:

"electronPackagerConfig": {
        "name": "SomeAppName",
        "icon": "./res/icon.icns",
        "osxSign": true
      },

for example name and icon properties work correctly but setting osxSign does not do anything

btw running signing command manually works correctly too:

electron-osx-sign "./out/myapp-darwin-x64/myapp.app" --platform=darwin --type=development

can anyone suggest anything?

Console output when you run electron-forge with the environment variable DEBUG=electron-forge:*. (Instructions on how to do so here). Please include the stack trace if one exists.

electron-forge:packager packaging with options { asar: false,
  overwrite: true,
  name: 'Ublend',
  icon: './res/icon.icns',
  osxSign: true,
  afterCopy: [ [Function], [Function], [Function], [Function] ],
  afterExtract: [],
  dir: '/Users/GURO/ublend/ublend-electron-app',
  arch: 'x64',
  platform: 'darwin',
  out: '/Users/GURO/ublend/ublend-electron-app/out',
  electronVersion: '1.4.15',
  quiet: true } +9ms
  electron-forge:lifecycle Process Succeeded: Preparing to Package Application for arch: x64 +12s
  electron-forge:lifecycle Process Started: Compiling Application +2ms
  electron-forge:lifecycle Process Succeeded: Compiling Application +919ms
  electron-forge:lifecycle Process Started: Preparing native dependencies +1ms
  electron-forge:lifecycle Process Succeeded: Preparing native dependencies +104ms
  electron-forge:lifecycle Process Started: Packaging Application +0ms
  electron-forge:lifecycle Process Succeeded: Packaging Application +8s

What command line arguments are you passing?

nothing

What does your config.forge data in package.json look like?

 "config": {
    "forge": {
      "make_targets": {
        "win32": [
          "squirrel"
        ],
        "darwin": [
          "dmg","zip"
        ],
        "linux": [
          "deb",
          "rpm"
        ]
      },
      "electronPackagerConfig": {
        "name": "MyApp",
        "icon": "./res/icon.icns",
        "osxSign": true
      },
      "electronWinstallerConfig": {
        "name": ""
      },
      "electronInstallerDebian": {},
      "electronInstallerRedhat": {},
      "github_repository": {
        "owner": "",
        "name": ""
      },
      "windowsStoreConfig": {
        "packageName": ""
      }
    }
  }

Please provide either a failing minimal testcase (with a link to the code) or detailed steps to
reproduce your problem. Using electron-forge init is a good starting point, if that is not the
source of your problem.

@MarshallOfSound
Copy link
Member

As answered on Slack. electron-packager hasn't been released yet with a version that supports osxSign, in the mean time use osx-sign.

/cc @malept Am I correct ^^

@malept
Copy link
Member

malept commented Mar 7, 2017

That's correct. In fact I found some weirdness this morning related to the API naming change, so it's probably a good thing that I didn't release yet. 😰

@justechn
Copy link

justechn commented May 10, 2017

is this working now or is osx-sign still prefered?

@malept
Copy link
Member

malept commented May 10, 2017

The change in Packager was released in 8.6.0, which was on March 14.

@onassar
Copy link

onassar commented Mar 9, 2018

Any update here?
I'm absolutely confused on how to get electron-forge to properly sign the app.

@malept malept changed the title Problem with electron-packager and osxSign osxSign is not supported until Electron Packager 8.6.0 Mar 9, 2018
@malept
Copy link
Member

malept commented Mar 9, 2018

Use osxSign inside forge.config.electronPackagerConfig, see the Electron Packager API docs for details.

@onassar
Copy link

onassar commented Mar 10, 2018

Okay great figured it out. For anyone else stumbling on this thread, this is what worked for me:

"osxSign": {
  "identity": "Mac Developer: NAME (ID CODE HERE)"
},

@joshuapinter
Copy link

@onassar Thank you so much for clarifying this. I felt like I was taking crazy pills looking for this. I suppose that's what happens when you have a umbrella framework that is puppeteering all of these other libraries and you have to go spelunking through each library to find what configuration is required.

Anyway, your config worked great. Mine ended up looking like this:

"electronPackagerConfig": {
  "osxSign": {
    "identity": "Developer ID Application: Joshua Pinter (<my_id>)"
  }
}

@onassar
Copy link

onassar commented May 23, 2018

Great to hear @joshuapinter
Ya you're right on. What I find frustrating is that it's really easy to get started with Electron, but really hard to put together all the pieces to deliver a polished (and functional and tested) app. I think it's due to your point: umbrella framework that is doing an amazing job pulling together all the pieces, but alas, still juggling so many things that it requires us to go deep in a lot of different areas.

Good luck :)

@emcmanus
Copy link

emcmanus commented Nov 1, 2019

For anyone who finds this looking for a package.json config example, the new key is packagerConfig, not electronPackagerConfig, e.g.:

{
  "config": {
    "forge": {
      "packagerConfig": {
        "osxSign": {
          "identity": "Developer ID Application: Company (<id>)"
        }
      }
    }
  }
}

dsanders11 pushed a commit that referenced this issue Jan 14, 2023
feat: support upcoming Electron 5.0 with nodeIntegration disabled by default
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

7 participants