I am trying to run a Gitlab pipeline that builds an AWS-CDK project via the cdk-synth command. I have followed advice online in terms of what images I should be using in the Gitlab runner but I am running into the following error:
Error: spawnSync docker ENOENT
I'm not sure what this error means exactly, I guess it is trying to launch docker (which is used by thecdk synth
command) but failing to do so. Again what I have found online all suggests to use the setup I currently have which is:
image: node:16.3.0-alpine
stages:
- build
- test
- .post
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- .npm
- node_modules
build:
tags:
- mytag
environment: ${CI_COMMIT_BRANCH}
stage: build
script:
- npm i
- cdk synth --no-staging > template.yaml
artifacts:
paths:
- cdk.out
expire_in: 30 mins
I'm really lost with this one, it may be staring me right in the face but could someone please point me in the right direction as to why i'd be getting this error when the image i'm using is itself a docker container?