Giter Club home page Giter Club logo

Comments (3)

BJClark avatar BJClark commented on September 24, 2024

@NickDarvey did you ever figure out a work around? I'm having the same issue

from org-formation-reference.

OlafConijn avatar OlafConijn commented on September 24, 2024

hi!
completely missed this before.
The error is: ERROR: Roles may not be assumed by root accounts.
I kinda wonder what the intention was behind running these commands as root, but this step will need to be ran as an IAM user.

you might already have an IAM user provisioned in the target account (or otherwise temporarily create one) you can use by running aws configure or setting up your credentials in ~/.aws/credentials.

from org-formation-reference.

stefan-karlsson avatar stefan-karlsson commented on September 24, 2024

I managed to run the script after the following changes:

  1. Created an IAM account in my MasterAccount
  2. Assigned the predefined AdministratorAccess Permissions policy to the user created in 1.
  3. Added a custom inline policy to allow assuming a role:
{
	"Version": "2012-10-17",
	"Statement": [
		{
			"Sid": "AssumeRole",
			"Effect": "Allow",
			"Action": "sts:AssumeRole",
			"Resource": "*"
		}
	]
}
  1. Generated access keys for the IAM user created in step 1
  2. Configured my AWS CLI to use the access key generated in step 4
  3. Executed the following command to create the OrganizationFormationBuildAccessRole role:
    aws cloudformation create-stack --stack-name org-formation-role --template-body file://src/templates/000-org-build/role.yml --region eu-north-1 --capabilities CAPABILITY_NAMED_IAM
  4. Ensured to update line 74 and line 77 with the correct email domain and address.
  5. Finally executed npx org-formation update ./src/organization.yml --verbose to build.

This seems to be the expected procedure! If so, updating the documentation or creating a bootstrap script for this would be beneficial. I am happy to help out!

from org-formation-reference.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.