0

我需要更改 packer 从 /tmp/packer-shell975270284 运行 AMI 配置脚本的目录,因为我们的实例不允许从 /tmp 运行脚本。

此脚本需要在 /opt 或 /home/ec2-user 中运行。它将在哪里获得权限

以下是我在运行 ansible playbook 后遇到的错误。

==> amazon-ebs: Provisioning with shell script: /tmp/packer-shell975270284
Build 'amazon-ebs' errored: Error uploading script: scp: /tmp/script_5412.sh: Permission denied.

==> Some builds didn't complete successfully and had errors.

==> Builds finished but no artifacts were created.
4

1 回答 1

0

您需要将 设置remote_folder为其他内容而不是/tmp. 请参阅文档

于 2019-09-06T11:59:09.800 回答