Skip to content
This repository was archived by the owner on Feb 14, 2023. It is now read-only.
This repository was archived by the owner on Feb 14, 2023. It is now read-only.

Working with sls3? #20

@digitalkaoz

Description

@digitalkaoz

i dont know how to use this plugin, here is my use case:

the to be imported config:

# sls.provider.go.yml
provider:
  name: aws
  runtime: go1.x
  region: ${opt:region, 'eu-central-1'}
  stage: ${opt:stage, 'int'}
  logRetentionInDays: 90
  memorySize: 256
  lambdaHashingVersion: "20201221"
  timeout: 60
  vpc:
    securityGroupIds: ${self:custom.ENV_CONFIG.SECURITY_GROUP_IDS}
    subnetIds: ${self:custom.ENV_CONFIG.PRIVATE_SUBNET_IDS}
  stackTags: ${self:provider.tags}
  tags:
    PROJECT: 'jhps-dx'
    STACK: '${self:service}'
    REGION: '${self:provider.region}'
    STAGE: '${self:provider.stage}'
# serverless.yml
service: my-service-name

package:
  individually: true

plugins:
  - serverless-import-config-plugin

custom:
  ENV_CONFIG: ${file(serverless.${self:provider.stage}.conf.yml)}
  import:
    - ./sls.provider.go.yml

functions:
# ...

the output is this:

$ serverless deploy --verbose --conceal -s int --region eu-central-1

Environment: darwin, node 17.5.0, framework 3.2.1, plugin 6.0.0, SDK 4.3.1
Docs:        docs.serverless.com
Support:     forum.serverless.com
Bugs:        github.com/serverless/serverless/issues

Error:
Invalid service configuration: "provider.name" property is missing

so how is this plugin supposed to work? reading all the other issues or the docs wasnt helpful et all...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions