I've come across a project http://scrapoxy.readthedocs.io/ which can be installed on ec2. I'm trying to follow the quickstart (http://scrapoxy.readthedocs.io/en/master/quick_start/index.html) I've created an ec2 ubuntu instance and performed steps 1 and 2 in the screenshot. The instructions are not clear and I'm not experienced with docker, but am I supposed to ssh into my ec2 instance and "run the container" from the command line?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
You are correct that you will have to SSH into your EC2 instance. You are also going to have to install Docker if it is not already installed. You can find some good instructions for that here
Typically, with docker images, you have to perform the following:
- Pull the image locally
- Create a container
- Start the container
The run command that you see in the instructions basically combines these 3 steps.
If it's easier to understand, or you need to take action between each step, you can also run the 3 steps individually. This is typically how I do it
- docker pull fabienvauchelles/scrapoxy
- docker create --name scraproxy -e COMMANDER_PASSWORD='CHANGE_THIS_PASSWORD' \ -e PROVIDERS_AWSEC2_ACCESSKEYID='YOUR ACCESS KEY ID' \ -e PROVIDERS_AWSEC2_SECRETACCESSKEY='YOUR SECRET ACCESS KEY' \ -it -p 8888:8888 -p 8889:8889 fabienvauchelles/scrapoxy
- docker start scraproxy
You can then use docker ps to view running containers