aws-opsworks

AWS opswork cloud formation unable to import

ε祈祈猫儿з 提交于 2021-01-29 16:34:57
问题 I am trying to import the cloud formation template for a Opswork VPC as per the guide here: https://aws.amazon.com/blogs/aws/aws-opsworks-in-the-virtual-private-cloud/ I tried importing but it keeps telling me that The following resource types are not supported for resource import: AWS::EC2::VPCGatewayAttachment,AWS::EC2::Route,AWS::EC2::SubnetRouteTableAssociation,AWS::EC2::NetworkAclEntry,AWS::EC2::NetworkAclEntry,AWS::EC2::NetworkAclEntry,AWS::EC2::NetworkAclEntry,AWS::EC2::NetworkAclEntry

Disable web access via direct IP address on AWS OpsWorks Nginx/Unicorn server

随声附和 提交于 2021-01-28 08:27:09
问题 I have a Rails app running on an AWS OpsWorks Nginx/Unicorn Rails Layer. I want my app to only process requests to api.mydomain.com and have my web server directly return a 404 if any request is made using the server's IP address. I've implemented a custom cookbook that overrides unicorn/templates/default/nginx_unicorn_web_app.erb (from the opsworks-cookbooks repo: https://github.com/aws/opsworks-cookbooks). I copied the template file that exists in this repository and added a new server

Get Custom JSON from Stack Settings in AWS OpsWorks with Chef 12

江枫思渺然 提交于 2020-07-22 05:38:24
问题 I'm currently working on the OpsWorks stacks with Chef 12, writing my own deploying recipes. Is there any possibilities to get the content of the field "Custom JSON" in Stack Settings? Cheers, xiGUAwanOU 回答1: All that data gets set as node attributes, so you can access it as per normal via the node object. 来源: https://stackoverflow.com/questions/39707501/get-custom-json-from-stack-settings-in-aws-opsworks-with-chef-12

how to show specific ec2 instance for an user

人走茶凉 提交于 2019-12-31 04:17:10
问题 I have some aws ec2 instances and would like to show ONLY one instance for partners. I created IAM user for the partner. following is my policy I created. But when partner logins to aws and see ec2 instance view, following message displayed and no instance is displayed. An error occurred fetching instance data: You are not authorized to perform this operation. { "Version": "2012-10-17", "Statement": [ { "Action": [ "ec2:*" ], "Sid": "Stmt1373378552000", "Resource": [ "arn:aws:ec2:ap-northeast

Windows Puppet agent does not connect to the AWSOpsWorks Puppet Enterprise master

不打扰是莪最后的温柔 提交于 2019-12-30 10:52:58
问题 I have created the puppet master using aws opsworks. and I am able to add ami linux nodes automatically to the puppet master. I am having issues when I tried to to add a windows 64 bit node to my puppet master by following this link https://puppet.com/docs/pe/2017.3/installing/installing_agents.html#install-windows-agents-with-the-msi-package I copied the puppet-agent-x64.msi from the puppet master present in location to the windows node and /opt/puppetlabs/server/data/packages/public/

Windows Puppet agent does not connect to the AWSOpsWorks Puppet Enterprise master

╄→尐↘猪︶ㄣ 提交于 2019-12-30 10:52:23
问题 I have created the puppet master using aws opsworks. and I am able to add ami linux nodes automatically to the puppet master. I am having issues when I tried to to add a windows 64 bit node to my puppet master by following this link https://puppet.com/docs/pe/2017.3/installing/installing_agents.html#install-windows-agents-with-the-msi-package I copied the puppet-agent-x64.msi from the puppet master present in location to the windows node and /opt/puppetlabs/server/data/packages/public/

Windows Puppet agent does not connect to the AWSOpsWorks Puppet Enterprise master

本秂侑毒 提交于 2019-12-30 10:52:21
问题 I have created the puppet master using aws opsworks. and I am able to add ami linux nodes automatically to the puppet master. I am having issues when I tried to to add a windows 64 bit node to my puppet master by following this link https://puppet.com/docs/pe/2017.3/installing/installing_agents.html#install-windows-agents-with-the-msi-package I copied the puppet-agent-x64.msi from the puppet master present in location to the windows node and /opt/puppetlabs/server/data/packages/public/

Create an RDS Opsworks Layer by a Cloudformation template

好久不见. 提交于 2019-12-25 08:27:19
问题 I'm making a CloudFormation template that creates an opsworks stack, layers and few applications. Within my layers, I have opsworks ones and RDS ones. In the AWS documentation, there is only how to create Opsworks::Layer but I don't know how to make an Amazon RDS service layer: { "Type": "AWS::OpsWorks::Layer", "Properties": { "Attributes" : { String:String }, "AutoAssignElasticIps" : Boolean, "AutoAssignPublicIps" : Boolean, "CustomInstanceProfileArn" : String, "CustomJson" : JSON object,

Configure providers from variables, in a generic way

…衆ロ難τιáo~ 提交于 2019-12-24 13:16:50
问题 How can I create a recipe that will populate its attributes using the fiels from an instance of an object in a generic way? As an example, consider the following recipe: component = $auth_docker docker_image component.name do registry component.registry tag component.tag action :pull end When you have 50s of recipes that look like this, maintaining them really gets overwhelming. In Python, i would probably implement a solution that would look a bit like this: docker_image = DockerImage(**

How to run AWS SDK Opsworks Commands in AWS Lambda?

允我心安 提交于 2019-12-23 16:59:38
问题 I've got a very simple lambda function trying to use the AWS SDK to call opsworks.describeInstances. The code executes locally fine, however inside lambda, it times out with no error or feedback. var AWS = require('aws-sdk'); var opsworks = new AWS.OpsWorks({ apiVersion: 'latest', region: "us-east-1" }); exports.handler = function(event, context, callback) { var params = { LayerId: 'idoflayer' }; opsworks.describeInstances(params, function(err, data) { if (err) { return callback(err); }