镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

'InstanceIds' is a required property #82

Open

Description

@VihangaHeshan

I faced this below error, even though I properly included the AWS access Key.
AWS Error
I managed to get all available ec2 instances. But when I issue the command stop or start the EC2 instance, it gives me this error.
Please help me to resolve this issue ASAP.

Activity

  1. punkrokk commented on Oct 22, 2019

    @punkrokk
    Contributor

    @VihangaHeshan can you share your command you are running, removing any actual instance Ids or other sensitive info?

  2. VihangaHeshan commented on Oct 22, 2019

    @VihangaHeshan
    Author

    Hi @punkrokk ,
    Thank you for your reply.
    This my action yaml file.
    image

    This is the alias file to start EC2 instance.
    image

    This is the command that I execute in the Slack with my Bot.
    image

  3. punkrokk commented on Oct 22, 2019

    @punkrokk
    Contributor

    @VihangaHeshan A quick peek makes me wonder two things:

    1. Can you run this at the CLI? st2 run aws.ec2_start_instances InstanceID=i-13221321312...
    2. Is your Jinja command format backwards? In your command you do state - id.
    3. Is the dash being read in from the instance?

    I am not a chatops expert but may be able to help more after you answer these questions.

  4. VihangaHeshan commented on Oct 22, 2019

    @VihangaHeshan
    Author

    Hi @punkrokk,

    1. Still the same issue when I run the command at the CLI
      image
    2. State - id, that is when showing the result back to screen.
    3. I tried without the dash even. Still the same issue.
      image
      **I directly taken this code from Github stackstorm/ AWS page.
      As far as I know it says the error is in
      "Back
      {
      "stdout": "",
      "stderr": "Traceback (most recent call last):\n File "/opt/stackstorm/st2/lib/python3.6/site-packages/python_runner/python_action_wrapper.py", line 333, in \n obj.run()\n File "/opt/stackstorm/st2/lib/python3.6/site-packages/python_runner/python_action_wrapper.py", line 192, in run\n output = action.run(**self._parameters)\n File "/opt/stackstorm/packs/aws/actions/run.py", line 36, in run\n return self.do_method(module_path, cls, aws_action, **kwargs)\n File "/opt/stackstorm/packs/aws/actions/lib/action.py", line 158, in do_method\n for k, v in kwargs.copy(): #I removed items() and added copy()\nValueError: too many values to unpack (expected 2)\n",
      "exit_code": 1,
      "result": "None"
      }"

    I am not sure whether this error occurred due to Python version mismatch.

    By the way this is nothing to do with chatops, seems simple coding error or syntax error.
    Please help me!

  5. punkrokk commented on Oct 22, 2019

    @punkrokk
    Contributor
  6. VihangaHeshan commented on Oct 22, 2019

    @VihangaHeshan
    Author

    Still same :(
    image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions