mirror of
https://github.com/digital-asset/daml.git
synced 2024-09-11 04:45:57 +03:00
Release EE SDK tarballs and installer (#9086)
* Release EE SDK tarballs and installer As before, no way of testing this. I’ll do a snapshot afterwards. changelog_begin changelog_end * . changelog_begin changelog_end * . changelog_begin changelog_end * Rename EE artifacts changelog_begin changelog_end
This commit is contained in:
parent
63623dc9a4
commit
5cb857d902
@ -86,7 +86,7 @@ On Windows:
|
||||
|
||||
```
|
||||
bazel build //release:sdk-release-tarball
|
||||
tar -vxf .\bazel-bin\release\sdk-release-tarball.tar.gz
|
||||
tar -vxf .\bazel-bin\release\sdk-release-tarball-ce.tar.gz
|
||||
cd sdk-*
|
||||
daml\daml.exe install . --activate
|
||||
```
|
||||
|
@ -12,7 +12,9 @@ mkdir -p $OUTPUT_DIR/artifactory
|
||||
|
||||
|
||||
TARBALL=daml-sdk-$RELEASE_TAG-$NAME.tar.gz
|
||||
cp bazel-bin/release/sdk-release-tarball.tar.gz $OUTPUT_DIR/github/$TARBALL
|
||||
EE_TARBALL=daml-sdk-$RELEASE_TAG-$NAME-ee.tar.gz
|
||||
cp bazel-bin/release/sdk-release-tarball-ce.tar.gz $OUTPUT_DIR/github/$TARBALL
|
||||
cp bazel-bin/release/sdk-release-tarball-ee.tar.gz $OUTPUT_DIR/artifactory/$EE_TARBALL
|
||||
|
||||
# Platform independent artifacts are only built on Linux.
|
||||
if [[ "$NAME" == "linux" ]]; then
|
||||
|
@ -8,15 +8,22 @@ OUTPUT_DIR=$2
|
||||
|
||||
mkdir -p $OUTPUT_DIR/github
|
||||
INSTALLER=daml-sdk-$RELEASE_TAG-windows.exe
|
||||
mv "bazel-bin/release/windows-installer/daml-sdk-installer.exe" "$OUTPUT_DIR/github/$INSTALLER"
|
||||
EE_INSTALLER=daml-sdk-$RELEASE_TAG-windows-ee.exe
|
||||
mv "bazel-bin/release/windows-installer/daml-sdk-installer-ce.exe" "$OUTPUT_DIR/github/$INSTALLER"
|
||||
mv "bazel-bin/release/windows-installer/daml-sdk-installer-ee.exe" "$OUTPUT_DIR/artifactory/$EE_INSTALLER"
|
||||
chmod +wx "$OUTPUT_DIR/github/$INSTALLER"
|
||||
chmod +wx "$OUTPUT_DIR/artifactory/$EE_INSTALLER"
|
||||
cleanup () {
|
||||
rm -f signing_key.pfx
|
||||
}
|
||||
trap cleanup EXIT
|
||||
echo "$SIGNING_KEY" | base64 -d > signing_key.pfx
|
||||
MSYS_NO_PATHCONV=1 signtool.exe sign '/f' signing_key.pfx '/fd' sha256 '/tr' "http://timestamp.digicert.com" '/v' "$(Build.StagingDirectory)/$INSTALLER"
|
||||
for path in "$OUTPUT_DIR/github/$INSTALLER" "$OUTPUT_DIR/artifactory/$EE_INSTALLER"; do
|
||||
MSYS_NO_PATHCONV=1 signtool.exe sign '/f' signing_key.pfx '/fd' sha256 '/tr' "http://timestamp.digicert.com" '/v' "$path"
|
||||
done
|
||||
rm signing_key.pfx
|
||||
trap - EXIT
|
||||
TARBALL=daml-sdk-$RELEASE_TAG-windows.tar.gz
|
||||
cp bazel-bin/release/sdk-release-tarball.tar.gz "$OUTPUT_DIR/github/$TARBALL"
|
||||
EE_TARBALL=daml-sdk-$RELEASE_TAG-windows-ee.tar.gz
|
||||
cp bazel-bin/release/sdk-release-tarball-ce.tar.gz "$OUTPUT_DIR/github/$TARBALL"
|
||||
cp bazel-bin/release/sdk-release-tarball-ee.tar.gz "$OUTPUT_DIR/artifactory/$EE_TARBALL"
|
||||
|
@ -8,7 +8,7 @@ RELEASE_TAG=$2
|
||||
|
||||
# We’ve already published to GH so focus on artifactory
|
||||
|
||||
INPUTS=$STAGING_DIR/release-artifacts/other
|
||||
INPUTS=$STAGING_DIR/release-artifacts/artifactory
|
||||
|
||||
push() {
|
||||
local file repository local_path md5 sha1
|
||||
@ -33,3 +33,12 @@ push daml-trigger-runner $TRIGGER_RUNNER
|
||||
push daml-trigger-runner $TRIGGER_RUNNER.asc
|
||||
push daml-script-runner $SCRIPT_RUNNER
|
||||
push daml-script-runner $SCRIPT_RUNNER.asc
|
||||
|
||||
for platform in linux macos windows; do
|
||||
EE_TARBALL=daml-sdk-$RELEASE_TAG-$platform-ee.tar.gz
|
||||
push sdk-ee $EE_TARBALL
|
||||
push sdk-ee $EE_TARBALL.asc
|
||||
done
|
||||
EE_INSTALLER=daml-sdk-$RELEASE_TAG-windows-ee.exe
|
||||
push sdk-ee $EE_INSTALLER
|
||||
push sdk-ee $EE_INSTALLER.asc
|
||||
|
@ -43,6 +43,6 @@ bazel build `
|
||||
//release:sdk-release-tarball `
|
||||
//ledger/ledger-api-test-tool:ledger-api-test-tool_deploy.jar
|
||||
|
||||
cp -Force bazel-bin\release\sdk-release-tarball.tar.gz compatibility/head_sdk
|
||||
cp -Force bazel-bin\release\sdk-release-tarball-ce.tar.gz compatibility/head_sdk
|
||||
cp -Force bazel-bin\ledger\ledger-api-test-tool\ledger-api-test-tool_deploy.jar compatibility/head_sdk
|
||||
cp -Force templates\create-daml-app-test-resources\messaging.patch compatibility/head_sdk
|
||||
|
@ -21,6 +21,6 @@ bazel build \
|
||||
//release:sdk-release-tarball \
|
||||
//ledger/ledger-api-test-tool:ledger-api-test-tool_deploy.jar
|
||||
|
||||
cp -f bazel-bin/release/sdk-release-tarball.tar.gz "$HEAD_TARGET_DIR"
|
||||
cp -f bazel-bin/release/sdk-release-tarball-ce.tar.gz "$HEAD_TARGET_DIR"
|
||||
cp -f bazel-bin/ledger/ledger-api-test-tool/ledger-api-test-tool_deploy.jar "$HEAD_TARGET_DIR"
|
||||
cp -f templates/create-daml-app-test-resources/messaging.patch "$HEAD_TARGET_DIR"
|
||||
|
@ -27,7 +27,7 @@ withSdkResource f =
|
||||
withTempDirResource $ \getDir ->
|
||||
withResource (installSdk =<< getDir) restoreEnv (const $ f getDir)
|
||||
where installSdk targetDir = do
|
||||
releaseTarball <- locateRunfiles (mainWorkspace </> "release" </> "sdk-release-tarball.tar.gz")
|
||||
releaseTarball <- locateRunfiles (mainWorkspace </> "release" </> "sdk-release-tarball-ce.tar.gz")
|
||||
oldPath <- getSearchPath
|
||||
withTempDir $ \cacheDir -> do
|
||||
withTempDir $ \extractDir -> do
|
||||
|
@ -137,9 +137,9 @@ function cleanup() {
|
||||
trap cleanup EXIT
|
||||
|
||||
# Building here separately so the user can see the build process which could take a while
|
||||
bazel build ${BAZEL_MODE_FLAGS[@]:-} //release:sdk-release-tarball.tar.gz
|
||||
bazel build ${BAZEL_MODE_FLAGS[@]:-} //release:sdk-release-tarball-ce.tar.gz
|
||||
|
||||
readonly TARBALL="$(bazel info bazel-bin ${BAZEL_MODE_FLAGS[@]:-})/release/sdk-release-tarball.tar.gz"
|
||||
readonly TARBALL="$(bazel info bazel-bin ${BAZEL_MODE_FLAGS[@]:-})/release/sdk-release-tarball-ce.tar.gz"
|
||||
readonly SDK_TEMP_DIR="$(mktemp -d)"
|
||||
readonly SDK_DIR="${SDK_TEMP_DIR}/sdk-head"
|
||||
mkdir -p "$SDK_DIR"
|
||||
|
@ -67,6 +67,20 @@ protos_zip(
|
||||
name = "protobufs",
|
||||
) if not is_windows else None
|
||||
|
||||
sdk_tarball("sdk-release-tarball", sdk_version, "community")
|
||||
[
|
||||
sdk_tarball(
|
||||
"sdk-release-tarball-{}".format(edition),
|
||||
sdk_version,
|
||||
edition,
|
||||
)
|
||||
for edition in [
|
||||
"ce",
|
||||
"ee",
|
||||
]
|
||||
]
|
||||
|
||||
sdk_tarball("sdk-release-tarball-ee", sdk_version, "enterprise")
|
||||
alias(
|
||||
name = "sdk-release-tarball",
|
||||
actual = "sdk-release-tarball-ce",
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
||||
|
@ -27,8 +27,8 @@ inputs = {
|
||||
"trigger_dars": "//triggers/daml:daml-trigger-dars",
|
||||
"script_dars": "//daml-script/daml:daml-script-dars",
|
||||
"sdk_deploy_jar": {
|
||||
"community": "//daml-assistant/daml-sdk:sdk_deploy.jar",
|
||||
"enterprise": "//daml-assistant/daml-sdk:sdk_ee_deploy.jar",
|
||||
"ce": "//daml-assistant/daml-sdk:sdk_deploy.jar",
|
||||
"ee": "//daml-assistant/daml-sdk:sdk_ee_deploy.jar",
|
||||
},
|
||||
}
|
||||
|
||||
|
@ -17,28 +17,34 @@ da_haskell_binary(
|
||||
deps = ["//:sdk-version-hs-lib"],
|
||||
)
|
||||
|
||||
genrule(
|
||||
name = "windows-installer",
|
||||
# daml-logo.ico was created with the following command:
|
||||
# convert \
|
||||
# docs/theme/da_theme_skeleton/static/images/favicon/apple-touch-icon.png \
|
||||
# -define icon:auto-resize=64,48,32,16 release/windows-installer/daml-logo.ico
|
||||
srcs = [
|
||||
"//release:sdk-release-tarball.tar.gz",
|
||||
":daml-logo.ico",
|
||||
],
|
||||
outs = ["daml-sdk-installer.exe"],
|
||||
cmd = """
|
||||
[
|
||||
genrule(
|
||||
name = "windows-installer-{}".format(edition),
|
||||
# daml-logo.ico was created with the following command:
|
||||
# convert \
|
||||
# docs/theme/da_theme_skeleton/static/images/favicon/apple-touch-icon.png \
|
||||
# -define icon:auto-resize=64,48,32,16 release/windows-installer/daml-logo.ico
|
||||
srcs = [
|
||||
"//release:sdk-release-tarball-{}.tar.gz".format(edition),
|
||||
":daml-logo.ico",
|
||||
],
|
||||
outs = ["daml-sdk-installer-{}.exe".format(edition)],
|
||||
cmd = """
|
||||
set -eou pipefail
|
||||
rm -rf release-dir
|
||||
mkdir -p release-dir
|
||||
tar xf $(location //release:sdk-release-tarball.tar.gz) --strip-components=1 -C release-dir
|
||||
tar xf $(location //release:sdk-release-tarball-{edition}.tar.gz) --strip-components=1 -C release-dir
|
||||
$(location :windows-installer-gen) ./installer.nsi release-dir $(location :daml-logo.ico)
|
||||
$(location @makensis_dev_env//:makensis) ./installer.nsi
|
||||
cp ./daml-sdk-installer.exe $(location daml-sdk-installer.exe)
|
||||
""",
|
||||
tools = [
|
||||
":windows-installer-gen",
|
||||
"@makensis_dev_env//:makensis",
|
||||
],
|
||||
) if is_windows else None
|
||||
cp ./daml-sdk-installer.exe $(location daml-sdk-installer-{edition}.exe)
|
||||
""".format(edition = edition),
|
||||
tools = [
|
||||
":windows-installer-gen",
|
||||
"@makensis_dev_env//:makensis",
|
||||
],
|
||||
)
|
||||
for edition in [
|
||||
"ce",
|
||||
"ee",
|
||||
]
|
||||
] if is_windows else None
|
||||
|
Loading…
Reference in New Issue
Block a user