Deploying the Tool in a Docker Container
To manually deploy the DevKit in a container, perform the following operations.
Environment Requirements
- Before installing the tool, install the following commands:
- ip
- passwd
- which
- file
- The running host supports only the Kunpeng platform.
Table 1 describes the OS requirements.
Procedure
For details about how to install, deploy, and perform basic operations on a Docker container, see Getting Started with Docker.
- Create a Docker container in port mapping mode.
1docker run -p 8086:8086 --name containername IMAGE:TAG /usr/sbin/init
- --name: name of the container to be created.
- -p: port mapping in the Host_port:Container_port format.
- 8086 is the default HTTPS port number of the Kunpeng DevKit. You need to enter the mapped container port number during the tool installation. Specify the actual port numbers.
- IMAGE indicates the path of the imported Docker image, and TAG indicates the tag of the image. You can run the following command to query related information:
1docker images
- Access the Docker container.
1docker exec -it containerID /bin/bash
In this command, containerID indicates the container ID. You can run the following command on the host machine to query it:
1docker ps - Copy the software package to the Docker container.
1scp root@serverIP:serverpath dockerpath
- root is the user name of the host machine.
- serverIP specifies the IP address of the host machine.
- serverpath specifies the path of the DevKit software package on the host machine.
- dockerpath specifies the path of the DevKit software package on the container.
- Install the Kunpeng DevKit by following instructions in Installation. During the installation, the local IP address must be the container IP address. You can run the following command to query the IP address:
1docker inspect containerID
- After the installation is successful, the tool login address displayed is the address for directly accessing the container. To access the tool outside the container, replace the container IP address with the host IP address and replace the container port number with the host port number.
Parent topic: Common Operations