Setting up Python Interpreter and running Python Code on Docker Container
Mar 14, 2021
Hello, Connections!!π
π Task-Description:-
π Setting up Python Interpreter and running Python Code on Docker Container.
1. Download the image which supports the python interpreter.
The Image I found is centos: 8, it supports a python interpreter.
Command used to download the image: docker pull centos:8
2. Now, Run the container using the centos image
Command used: docker run -it β name myos2 centos:8
3. Download python3 using the DNF command
Command used: DNF install python3 -y
4. Check that python has installed or not
Command used: python3 -V
5. Create a python File and run it
Command used: mkdir pythoncode
cd pythoncode
vi hello.py
The file has successfully run. Hello printed.
Thank You !!