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 info airnode-deployer command #1477

Merged
merged 1 commit into from
Sep 30, 2022
Merged

Add info airnode-deployer command #1477

merged 1 commit into from
Sep 30, 2022

Conversation

amarthadan
Copy link
Contributor

Close #1404

As I noted in the code, there will be some refactoring once #1473 is done (or rather as part of that)

@amarthadan amarthadan requested a review from a team September 27, 2022 07:48
@amarthadan amarthadan self-assigned this Sep 27, 2022
@amarthadan amarthadan linked an issue Sep 27, 2022 that may be closed by this pull request
Copy link
Contributor

@Siegrift Siegrift left a comment

Choose a reason for hiding this comment

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

Did a quick look, I agree that cleanup is necessary, but can be done later.

const goDeploymentInfo = await go(() => deploymentInfo(args.deploymentId as string));
if (!goDeploymentInfo.success) {
// eslint-disable-next-line functional/immutable-data
process.exitCode = 1;
Copy link
Contributor

Choose a reason for hiding this comment

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

Isn't this too harsh? Will there be a message logged out?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, there will be https://github.com/api3dao/airnode/blob/deployment-info/packages/airnode-deployer/src/infrastructure/index.ts#L694
I think it should end up with the non-zero exit code when it can't find the deployment. It's the same thing as when you call docker inspect <ID> with an invalid/non-existent ID.

consoleLog(`Airnode version: ${airnodeVersion}`);
consoleLog(`Deployment ID: ${id}`);
const tableString = table.toString();
const tableStringWithCurrent = tableString.replace(new RegExp(`(?<=${currentVersionId}.*?)\n`), ' (current)\n');
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

Copy link
Contributor

@Siegrift Siegrift left a comment

Choose a reason for hiding this comment

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

👍 LGTM. Works fine for my limited AWS test (see image)

image

@amarthadan amarthadan merged commit 52ad212 into temp-v0.10.0 Sep 30, 2022
@amarthadan amarthadan deleted the deployment-info branch September 30, 2022 11:27
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.

Allow users to retrieve info about their deployments
2 participants