I built a CodeBuild project for a fairly simple build pipeline. I am building a NodeJS project. My buildspec is pretty simple:
version: 0.2
env:
variables:
ENVIRNOMENT: "AWSDEV"
phases:
pre_build:
commands:
- npm install
build:
commands:
- npm run -s build
artifacts:
files:
- src/dist/**/*
- node_modules/**/*
discard-paths: no
The npm run build step simply uses Babel to transpile the code into the src/dist directory. I'm running a build and it's been 37 minutes and it's still building, on the step UPLOAD_ARTIFACTS. I can see the artifacts being added to the S3 bucket so it's presumably actually still doing stuff.
Is there anything I can do to improve this build process? This should be a short, 5 minute at most task I would think. Am I doing something wrong by uploading node_modules to the S3 bucket?
What is the best configuration for a Node project?