Functions sometimes rely on outside services from Amazon such as S3, and accessing these resources often requires authorization using IAM. Spotinst Functions can be configured with the relevant permissions with the inclusion of IAM role information in the serverless.yml file. See Amazon's documentation for more information on IAM roles.
- You will need to create an IAM role on your AWS account and attach policies with the relevant permissions.
- A spotinst role will be generated and linked with your AWS role
- Only one Spotinst role per function.
- Multiple functions can be associated with the same Spotinst role.
functions: example: runtime: nodejs8.3 handler: handler.main memory: 128 timeout: 30 access: private iamRoleConfig:
- roleId: the role created on the Spotinst console
- ex : sfr-5ea76784