Skip to content

Commit

Permalink
fix: login should happen at the begining
Browse files Browse the repository at this point in the history
  • Loading branch information
rolljee committed Dec 10, 2024
1 parent e384845 commit 6df9f80
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,12 @@ class Action {
}

async run() {
await this.login();

if (this.inputs.login_only) {
return;
}

if (!this.inputs.image) {
throw new Error(
`You're attempting to deploy but you didn't provide a Docker image name to do so.`
Expand All @@ -262,11 +268,6 @@ class Action {
throw new Error(`Project name required for deployment operations.`);
}

await this.login();

if (this.inputs.login_only) {
return;
}

await this.deploy();

Expand Down

0 comments on commit 6df9f80

Please sign in to comment.