diff --git a/images/linux/ubuntu1604.json b/images/linux/ubuntu1604.json index 3625b7ed2..82cb0f06e 100644 --- a/images/linux/ubuntu1604.json +++ b/images/linux/ubuntu1604.json @@ -90,6 +90,7 @@ }, { "type": "shell", + "execute_command": "chmod +x {{ .Path }}; sudo {{ .Vars }} {{ .Path }}", "scripts":[ "{{template_dir}}/scripts/installers/preparemetadata.sh" ], @@ -98,8 +99,7 @@ "METADATA_FILE={{user `metadata_file`}}", "HELPER_SCRIPTS={{user `helper_script_folder`}}", "ANNOUNCEMENTS={{user `announcements`}}" - ], - "execute_command": "sudo sh -c '{{ .Vars }} {{ .Path }}'" + ] }, { "type": "shell", diff --git a/images/linux/ubuntu1804.json b/images/linux/ubuntu1804.json index b5037520d..e9c756f15 100644 --- a/images/linux/ubuntu1804.json +++ b/images/linux/ubuntu1804.json @@ -93,6 +93,7 @@ }, { "type": "shell", + "execute_command": "chmod +x {{ .Path }}; sudo {{ .Vars }} {{ .Path }}", "scripts":[ "{{template_dir}}/scripts/installers/preparemetadata.sh" ], @@ -101,8 +102,7 @@ "METADATA_FILE={{user `metadata_file`}}", "HELPER_SCRIPTS={{user `helper_script_folder`}}", "ANNOUNCEMENTS={{user `announcements`}}" - ], - "execute_command": "sudo sh -c '{{ .Vars }} {{ .Path }}'" + ] }, { "type": "shell",