Comments (7)
I've got a couple of other things I want to add and I'll try to get 0.4.0 released in the next few days.
from aws-sam-webpack-plugin.
@daveykane I think I have a similar problem. If I understand you correctly then I could solve this by adding projectDirs
to the plugin options with a default value ["."]
. It would treat each folder in projectDirs
as its own SAM project expecting a template.yaml
with the config and creating a .aws-sam
for the output.
Example:
If I set projectDirs: ["project1", "project2"]
then it build project1 using project1/template.yaml
with the output going to project1/.aws-build
and project2 using project2/template.yaml
with the output going to project2/.aws-build
. You would still need to run sam package
and sam deploy
in each of the project folders.
If I don't set projectsDirs
then it defaults to ["."]
so it looks for template.yaml
in the current folder with output going to .aws-sam
in the same folder.
Does this sound correct?
from aws-sam-webpack-plugin.
@buggy yes that sounds like it would work to me, good shout.
I saw you also made an update for the next release to skip functions using inline code, thanks for that and thanks for the great work on the plugin so far.
from aws-sam-webpack-plugin.
Hi @buggy
Thanks for such plugin, it's saved me really much time.
I just wonder what's the reason that name of template.yaml
is hardcoded? As I know sam allows to specify the name of template in command line.
from aws-sam-webpack-plugin.
I just wonder what's the reason that name of template.yaml is hardcoded?
It's just the way I built it. I picked template.yaml
and template.yml
because they're the two defaults that SAM uses. You're the first person to ask for it to support other names.
from aws-sam-webpack-plugin.
Yes, template.yaml
is used widely. I've just noted that compatibility with running sam build
is mentioned as one of the project goals, and sam
already has an option to specify path to template and that path can be arbitrary file name.
sam
is rather often used tool and this plugin is still gaining its popularity, so I believe I'm the first one, but not the last))
from aws-sam-webpack-plugin.
I've pushed experimental support for building multiple projects to the develop branch. Once I run some more tests I'll release version 0.5.0 with it.
@vadzim you can use the projects
option to have different template names.
from aws-sam-webpack-plugin.
Related Issues (20)
- Support for DefinitionUri in AWS::Serverless: :StateMachine HOT 8
- Generated template file should always be `template.yaml` HOT 1
- Possible Bug with compiling the webpack code HOT 8
- Can't use ES6 import/export HOT 3
- Best way of building source code when other runtimes exist in the project HOT 1
- Improve webpack build performance HOT 2
- NodeJS14 Support HOT 1
- Debugging on VSCode: payload and env vars? HOT 1
- Support for Node 14 HOT 3
- Multiply write into .aws-sam/template.yaml
- Debugging is broken with VS Code 1.60.0 HOT 5
- build.toml HOT 3
- Build process is breaking GraphQL endpoint when running SAM Local
- Would be possible to watch only one function? HOT 2
- Remove `"module": "commonJS"` in TSConfig Example to support Tree Shaking?
- Question about how to override template parameter during webpack building HOT 2
- Add a tag for Nodejs18.x HOT 2
- SAM deploying TypeScript source code instead of the transpiled JavaScript HOT 2
- Support ES Modules HOT 2
- <Function name> has an unsupport Runtime. Must be nodejs10.x or nodejs12.x
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aws-sam-webpack-plugin.