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

Add content hashes to release #441

Merged
merged 7 commits into from
Aug 14, 2024

Conversation

dappnodedev
Copy link
Contributor

@dappnodedev dappnodedev commented Jul 15, 2024

Release needs to include content hashes, as it is used to enable packages download in case there is no Ethereum node available: dappnode/DNP_CORE#184

With this code, the releases for standard packages will look like:

image

And the releases for multi-variant packages will look like:
image

Copy link

github-actions bot commented Jul 15, 2024

Dappnode bot has built and pinned the built packages to an IPFS node, for commit: 010521f

This is a development version and should only be installed for testing purposes.

  1. Package dappnodesdk.public.dappnode.eth

Install link

Hash: /ipfs/QmZBx6yqTxTWeoX74Kx36QUWqHt9rsCsCKjHXaiPSHdqwb

(by dappnodebot/build-action)

@dappnodedev dappnodedev marked this pull request as ready for review July 15, 2024 15:47
@dappnodedev dappnodedev requested a review from a team as a code owner July 15, 2024 15:47
@dappnodedev
Copy link
Contributor Author

The best approach would be merging #443 and then rebasing before merging this PR

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This file has no changes apart from identation

@@ -195,9 +198,9 @@ export class Github {
body?: string;
prerelease?: boolean;
}
): Promise<void> {
): Promise<number> {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Only change here: This funcion now returns releaseID

"content-type": contentType,
"content-length": fs.statSync(filepath).size
},
name: `${fileNamePrefix || ""}${path.basename(filepath)}`
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Adds prefix for multivariant packages. For example:

If variant is holesky for Obol package, content-hash file name will be holesky-obol_content-hash

}
};
}

async function handleReleaseVariantFiles({
function prepareGithubReleaseFiles({
Copy link
Contributor Author

@dappnodedev dappnodedev Jul 26, 2024

Choose a reason for hiding this comment

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

Creates content-hash file, compacts manifest and deletes build properties from compose

@dappnodedev dappnodedev marked this pull request as draft August 6, 2024 07:36
@dappnodedev dappnodedev force-pushed the bugfix/add-content-hashes-to-release branch from d4a5955 to eaa4d12 Compare August 6, 2024 09:02
@dappnodedev dappnodedev marked this pull request as ready for review August 6, 2024 13:47
@dappnodedev dappnodedev merged commit bc9f781 into master Aug 14, 2024
8 of 10 checks passed
@dappnodedev dappnodedev deleted the bugfix/add-content-hashes-to-release branch August 14, 2024 13:28
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

Successfully merging this pull request may close these issues.

2 participants