-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Add MacOS installer to packaging #7481
Conversation
dev-tools/mage/pkgtypes.go
Outdated
@@ -762,3 +803,16 @@ func addFileToTar(ar *tar.Writer, baseDir string, pkgFile PackageFile) error { | |||
return file.Close() | |||
}) | |||
} | |||
|
|||
func PackageDMG(spec PackageSpec) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported function PackageDMG should have comment or be unexported
dev-tools/mage/pkgtypes.go
Outdated
@@ -762,3 +803,16 @@ func addFileToTar(ar *tar.Writer, baseDir string, pkgFile PackageFile) error { | |||
return file.Close() | |||
}) | |||
} | |||
|
|||
func PackageDMG(spec PackageSpec) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported function PackageDMG should have comment or be unexported
c4c6276
to
6da50e5
Compare
I kicked off a build at https://beats-ci.elastic.co/job/elastic+beats+pull-request+package/38/console. This is with APPLE_SIGNING_ENABLED=false (default). I'll do another test later with that enabled. |
3b5dd90
to
0be8d48
Compare
|
a50795a
to
7818449
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work @andrewkroh
This adds the creation of a .dmg files when building packages on MacOS (the build host must be darwin with XCode installed). The .dmg file contains an installer (.pkg) and a rudimentary Uninstall.app. When code signing is enabled every part of the .dmg is signed. This is the structure of the package. - beat.dmg - beat.pkg - internal-beat.pkg - BeatPrefPane.pkg - Uninstall.app The following environment variables control the code signing behavior. - APPLE_SIGNING_ENABLED - Must be set to true to enable signing. Defaults to false. - APPLE_SIGNING_IDENTITY_INSTALLER - filter for selecting the signing identity for installers. It's effectively used as `security find-identity -v | grep $APPLE_SIGNING_IDENTITY_INSTALLER` to select a single certificate. - APPLE_SIGNING_IDENTITY_APP - filter for selecting the signing identity for apps. Co-authored-by: Adrian Serrano <adrisr83@gmail.com>
7818449
to
76526b9
Compare
Rebased to resolve conflicts with the Filebeat modules fix. This should be good to go after the packaging job completes. Build: https://beats-ci.elastic.co/job/elastic+beats+pull-request+package/46/console |
This adds the creation of a .dmg files when building packages on MacOS (the
build host must be darwin with XCode installed). The .dmg file contains an
installer (.pkg) and a rudimentary Uninstall.app. When code signing is enabled
every part of the .dmg is signed. This is the structure of the package.
The following environment variables control the code signing behavior.
false.
for installers. It's effectively used as
security find-identity -v | grep $APPLE_SIGNING_IDENTITY_INSTALLER
toselect a single certificate.
for apps.
Co-authored-by: Adrian Serrano @adriansr
Screenshots of the installed package: #6053 (comment)