Skip to content
This repository was archived by the owner on Mar 1, 2023. It is now read-only.

Changes for rest API Key based auth #31

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion dockers/docker-sonic-mgmt-framework/rest-server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

SERVER_PORT=
LOG_LEVEL=
CLIENT_AUTH=
CLIENT_AUTH=true
SERVER_CRT=
SERVER_KEY=
CA_CERT=
Expand Down
3 changes: 3 additions & 0 deletions files/image_config/platform/rc.local
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,9 @@ fi
# Create dir where following scripts put their output files
mkdir -p /var/platform

# Create dir for user API Keys
mkdir --mode=0700 -p /etc/rest_api_keys

# Write contents of system EEPROM as JSON file
/usr/bin/decode-syseeprom | /usr/bin/syseeprom-to-json > /var/platform/syseeprom

Expand Down
2 changes: 2 additions & 0 deletions rules/docker-sonic-mgmt-framework.mk
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ $(DOCKER_MGMT-FRAMEWORK)_CONTAINER_NAME = mgmt-framework
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += --net=host --privileged -t
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += -v /etc/sonic:/etc/sonic:ro
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += -v /etc:/host_etc:ro
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += -v /etc/rest_api_keys:/etc/rest_api_keys:rw
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += -v /:/host_root:ro
$(DOCKER_MGMT-FRAMEWORK)_RUN_OPT += --mount type=bind,source="/var/platform/",target="/mnt/platform/"

$(DOCKER_MGMT-FRAMEWORK)_BASE_IMAGE_FILES += sonic-cli:/usr/bin/sonic-cli