kong.conf.default is read only in Docker through Linux Containers

2.3k views Asked by At

After Kong has been installed in windows using docker (Linux containers), I need to update kong.conf.default or kong.conf file for few extra plugins.

enter image description here

When I am trying to update the kong.conf.default using the following command, it says me Read Only.

vi kong.conf.default

As well it is not providing me to chmod by following command and it throws error "chmod: kong.conf.default: Operation not permitted".

chmod 777 kong.conf.default

Please need your support. Advance thanks.

1

There are 1 answers

0
Maik On

copy the kong.conf.default outside the container, rename it to kong.conf, change it like you need it and mount it inside the container.

Look here my docker-compose.yml

version: '3'
services:

  kong:
    container_name: kong
    image: kong:2.1.3-centos
    environment:
      ...
    volumes:
      - ./kong.yml:/usr/local/kong/declarative/kong.yml
      - ./kong.conf:/etc/kong/kong.conf
    ports:
      ....