CREATE_FAILED - Failed to create [DashboardFunction]

Hi Andreas & Michael

I encountered AWS error messages when following the eBook (amazon.com) instruction to launch the demo infrastructure and application. The error message appears on the event log of the Cloudformation stack, as shown below:

“Embedded stack arn:aws:cloudformation:us-west-2:211082502635:stack/demo-app-Dashboard-WLX0OOO3H8FZ/68528210-b14c-11ea-aca7-0a21b227ca7e was not successfully created: The following resource(s) failed to create: [DashboardFunction].”

Following the instructions on the book, Here are the commands I entered and their returned messages. They were either from the desktop Powershell console or the running container:

PS D:\workbench\Docker\docker-on-aws-code>
PS D:\workbench\Docker\docker-on-aws-code> docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
cloudonaut/docker-on-aws-working-env latest f2ac0a339198 3 weeks ago 2.66GB
hello-world latest bf756fb1ae65 5 months ago 13.3kB
PS D:\workbench\Docker\docker-on-aws-code>
*PS D:\workbench\Docker\docker-on-aws-code> docker run -it --rm -v ${PWD}:/src:rw -v $HOME.aws:/root/.aws:rw -v $HOME.gitconfig:/root/.gitconfig:rw -v /var/run/docker.sock:/var/run/docker.sock cloudonaut/docker-on-aws-working-env
bash-4.2#
bash-4.2#
bash-4.2# npm -v
6.14.4
bash-4.2# node -v
v10.20.1
bash-4.2#
bash-4.2#
bash-4.2# npm i
added 20 packages from 3 contributors and audited 20 packages in 2.058s
found 0 vulnerabilities

*bash-4.2# aws cloudformation package --template-file template.yml --s3-bucket docker-on-aws-abel168 --output-template-file .template.yml
Uploading to d79208175f87b99ea8527695eb54866e.template 27143 / 27143.0 (100.00%)
Successfully packaged artifacts and wrote output template to file .template.yml.
Execute the following command to deploy the packaged template
aws cloudformation deploy --template-file /src/demo-app/aws/.template.yml --stack-name
*bash-4.2# aws cloudformation deploy --template-file .template.yml --stack-name demo-app --capabilities CAPABILITY_IAM

Waiting for changeset to be created…
Waiting for stack create/update to complete

Failed to create/update the stack. Run the following command
to fetch the list of events leading up to the failure
aws cloudformation describe-stack-events --stack-name demo-app

May I ask the following questions? thanks:

Q1. Am I supposed to run “aws cloudformation deploy …” statements inside the running container or from the desktop command prompt? Please confirm. I would suggest that all command statements shown on the eBook should be prefixed with a command prompt to indicate the working folder to execute the commands and the environment (i.e., the paths and also, whether inside the running container or from the desktop OS).

Q2. I read another closed message thread. It mentioned that the cause was due to Node.JS version. However, I had pulled the latest docker image (as of 18 Jun 2020, id:f2ac0a339198 ). The node and npm versions are 10.20.1 and 6.14.4 respectively. Is the latest version of the docker image supposed to have the correct versions of software? If not, what are the steps to upgrade the Node.JS inside the running container? Do I need to build the image again?

Q3. What is the exact reason for being unable to create the [DashboardFunction]? How to fix it? Thanks.

Q4. Michael mentioned in another closed message thread about “Rapid Docker on AWS update available”. How can I receive those messages about any updates (or error correction notice) of the book?

Thank you.

Cheers,
Abel

Hi Abel!

Q1: yes, you are supposed to run all commands inside the “temporary working environment” which is a Docker container based on our image

Q2: yes, you are right. I sent you a private message with the up-to-date download link. Unfortunately, the update process works only for customers that bought the book directly from us. Amazon does not provide us the contact information of the buyers.

Q3: The reason is that Lambda no longer supports Node.js 8.

Q4: We are still figuring out how we can keep the ebook up-to-date on Amazon.

I hope this helps.

Michael

Same problem here!

I bought your amazing book on Amazon (kindle version)

I would be nice getting notifications about book updates

Thanks in advance

1 Like

Hi Cobis,

I agree! The latest download link is on your way.

Michael

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.