diff --git a/amplify.yml b/amplify.yml index e69489b5..e7337a9f 100644 --- a/amplify.yml +++ b/amplify.yml @@ -1,12 +1,22 @@ version: 1 backend: phases: + preBuild: + commands: + - nvm install 22 + - nvm use 22 build: commands: - npm ci --cache .npm --prefer-offline - npx ampx pipeline-deploy --branch $AWS_BRANCH --app-id $AWS_APP_ID + frontend: phases: + preBuild: + commands: + - nvm use 22 + - npm ci + build: commands: - npm run build @@ -18,4 +28,4 @@ frontend: paths: - .next/cache/**/* - .npm/**/* - - node_modules/**/* \ No newline at end of file + - node_modules/**/* diff --git a/package.json b/package.json index 30fdfa58..5afdbe72 100644 --- a/package.json +++ b/package.json @@ -7,6 +7,7 @@ "build": "next build", "start": "next start", "lint": "next lint", + "prepare": "husky", "test": "jest", "test:watch": "jest --watch", "test:coverage": "jest --coverage"