How do I find OpsWorks deploy user in a recipe ?

0 votes

I have been trying to figure out, how to extract or find the name of the user who's performing the deployment of an app on a given OpsWorks stack. For example, in the "Deployments and Commands" section of a stack, the table there displays a history of various deployments with who the deploy user was... etc. I'd like to be able to capture that same user from within my recipe.

It doesn't look like it's something I can grab out of search(:aws_opsworks_app) databag (unless I'm mistaken). Or is there somewhere else I can get this information easily?

Can anyone help me with this query?

Thanks.

Jul 25, 2018 in DevOps Tools by Damon Salvatore
• 5,270 points
22 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

Here is a concept which you can follow:

Given below is an easier way to get it through search(:aws_opsworks_command) databag.

:aws_opsworks_command provides an iam_user_arn attribute which can be massaged to appear as the deployment user's IAM name. An example iam_user_arn string look like arn:aws:iam:555555:user/username

Example:

owc = search(:aws_opsworks_command).first
owc[:iam_user_arn].split(':').last
# => gets us "user/username"

Here is a link which you can follow for documentation purpose : https://docs.aws.amazon.com/opsworks/latest/userguide/data-bag-json-command.html

I hope that the above information would be helpful for you.

answered Jul 25, 2018 by Atul
• 10,200 points

Related Questions In DevOps Tools

+1 vote
3 answers

How do I check and export sonarqube analysis reports in embedded db?

Browse to sonarqube web instance to access ...READ MORE

answered Jul 2, 2018 in DevOps Tools by DareDev
• 6,560 points
1,522 views
0 votes
1 answer

How do I deploy to multiple servers using the same context root?

  If you're deploying to multiple servers ...READ MORE

answered Jul 2, 2018 in DevOps Tools by Kalgi
• 35,800 points
35 views
0 votes
1 answer

How do I manage code that *removes* users in chef?

No, I don't think this will prove ...READ MORE

answered Aug 6, 2018 in DevOps Tools by Damon Salvatore
• 5,270 points
18 views
0 votes
1 answer

How do I set maximum queue connection for nginx port in Windows?

Since increasing queue size did not fix your problem ...READ MORE

answered Aug 22, 2018 in DevOps Tools by Damon Salvatore
• 5,270 points
41 views
+13 votes
2 answers
0 votes
1 answer
0 votes
1 answer

How do I run “ant update” in Hybris with only “Update Running System”?

Here is what you can try. You can ...READ MORE

answered Jul 10, 2018 in DevOps Tools by Atul
• 10,200 points
779 views
0 votes
1 answer

How do I update configuration of a Cassandra cluster ?

Here is a way through which you ...READ MORE

answered Jul 26, 2018 in DevOps Tools by Atul
• 10,200 points
26 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.