Hello! I need to add a record to the hosts file in my app. Here is my config:
version: 2.1
jobs:
run_api_tests:
docker:
- image: circleci/node:14
steps:
- checkout
- run:
name: Install npm dependencies
command: |
npm ci
- run:
name: Run API tests
command: |
npm run test-api
workflows:
build_test:
jobs:
- run_api_tests
In my tests I am calling domain.com, so I’d like to add
domain.com 127.0.0.1
to the /etc/hosts
But how to do this? I get permissions denied if I try to modify the file. Thanks.