aws-samples / aws-samples/aws-codebuild-samples

Any sample for installing redis on buildspec.yml ?

Open
#20 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
242
Forks
452
PR merge metrics
No merged PRs in 30d

Description

This one doesn't work -

```
version: 0.2

phases:
install:
runtime-versions:
nodejs: 'latest'
commands:
- echo Updating system packages...
- yum update -y

- echo Enabling EPEL and Redis 6 from amazon-linux-extras...
- amazon-linux-extras install epel -y
- amazon-linux-extras install redis6 -y

- echo Starting Redis service and enabling at boot...
- systemctl start redis
- systemctl enable redis

- echo Verifying Redis installation...
- redis-server --version
- redis-cli --version

pre_build:
commands:
- npm install pm2
- echo Installing source NPM dependencies...
- npm ci

build:
commands:
- echo Build started on `date`
- echo Running build...
- npm run build
-
post_build:
commands:
- echo Build completed on `date`

artifacts:
files:
- "**/*"

```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.