Skip to content

feat: post-install actions#2266

Merged
mergify[bot] merged 24 commits intomasterfrom
spofford/postbuild
Jun 27, 2022
Merged

feat: post-install actions#2266
mergify[bot] merged 24 commits intomasterfrom
spofford/postbuild

Conversation

@adamspofford-dfinity
Copy link
Contributor

This adds the ability to specify post-installation tasks with a per-canister post-install key in dfx.json. Post-installation tasks receive the same environment variables that build tasks do.

@adamspofford-dfinity adamspofford-dfinity requested a review from a team as a code owner June 15, 2022 21:14
@adamspofford-dfinity adamspofford-dfinity requested a review from a user June 16, 2022 18:24

echo 'return 1' >> postinstall.sh
assert_command_fail dfx canister install postinstall_script --mode upgrade
assert_match hello
Copy link

Choose a reason for hiding this comment

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

can you explain why "hello" is expected in the output here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's expected because stdout is still printed; it's tested for to ensure that the script is why the command failed.

@ghost ghost added the automerge-squash label Jun 27, 2022
@mergify mergify bot merged commit 573d13d into master Jun 27, 2022
@mergify mergify bot deleted the spofford/postbuild branch June 27, 2022 23:11
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.

1 participant