-
-
Notifications
You must be signed in to change notification settings - Fork 364
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 command to deploy in local and give parameters to serverless invoke #9
Conversation
bref
Outdated
foreach ($buildHooks as $buildHook) { | ||
$io->writeln('Running ' . $buildHook); | ||
$commandRunner->run('cd .bref/output && ' . $buildHook); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR! If I'm not mistaken everything above this is duplicated from the deploy
command? Maybe that code could be shared instead, moved to a class maybe? I'm thinking a generate()
method in a src/Console/Deployer
class for example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes you are right, it's a big duplication of deploy command. I would just propose you this feature in a simple way to saw if it's was a good idea.
I will refacto this and send you a new commit
bref
Outdated
@@ -52,6 +52,104 @@ $app->command('init', function (SymfonyStyle $io) { | |||
]); | |||
}); | |||
|
|||
$app->command('local [data]', function(?string $data, SymfonyStyle $io) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add a comment above this line? Something that says something like "Runs the lambda locally".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok no problem
fix file path
In order to deploy on local machine with serveless I need to give some paremeters to the invoke function