/balena-io-library/official-images).

# How to use this image

## Create a `Dockerfile` in your Python app project

```dockerfile
FROM balenalib/colibri-imx6dl-debian-python:latest

WORKDIR /usr/src/app

COPY requirements.txt./
RUN pip install --no-cache-dir -r requirements.txt

COPY..

CMD [ "python", "./your-daemon-or-script.py" ]
```

You can then build and run the Docker image:

```console
$ docker build -t my-python-app.
$ docker run -it --rm --name my-running-app my-python-app
```

## Run a single Python script

For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Python script by using the Python Docker image directly:

```console
$ docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp balenalib/colibri-imx6dl-debian-python:latest python your-daemon-or-script.py
```

[example-projects]: https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/#example-projects?ref=dockerhub
[getting-started]: https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/?ref=dockerhub

# User Feedback

## Issues

If you have any problems with or questions about this image, please contact us through a [GitHub issue](https://github.com/balena-io-library/base-images/issues).

## Contributing

You are invited to contribute new features, fixes, or updates, large or small; we are always thrilled to receive pull requests, and do our best to process them as fast as we can.

Before you start to code, we recommend discussing your plans through a [GitHub issue](https://github.com/balena-io-library/base-images/issues
/balena - io - library / official - images). 

 # How to use this image 

 # # Create a 'Dockerfile 'in your Python app undertaking 

 '` 'dockerfile 
 FROM balenalib / colibri - imx6dl - debian - python: belated 

 WORKDIR /usr / src / app 

 COPY requirements.txt./ 
 RUN pip install --no - cache - dir -r requirements.txt 

 COPY.. 

 CMD [ " python ", " ./your - daemon - or - script.py " ] 
 '` '

 You can then build up and operate the Docker image: 

 '` 'console 
 $ stevedore build -t my - python - app. 
 $ docker run -it --rm --name my - run - app my - python - app 
 '` '

 # # Run a single Python handwriting 

 For many simple, single file projects, you may find it inconvenient to spell a complete 'Dockerfile `. In such cases, you can run a Python script by using the Python Docker persona directly: 

 '` 'console 
 $ docker rivulet -it --rm --name my - running - script -v " $ PWD":/usr / src / myapp -w /usr / src / myapp balenalib / colibri - imx6dl - debian - python: latest python your-daemon-or-script.py 
 '` '

 [ example - undertaking ]: https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/#example-projects?ref=dockerhub 
 [ getting - started ]: https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/?ref=dockerhub 

 # User Feedback 

 # # Issues 

 If you have any problems with or questions about this picture, please contact us through a [ GitHub issue](https://github.com / balena - io - library / base - images / issues). 

 # # Contributing 

 You are invite to contribute new features, fixes, or updates, large or small; we are always thrilled to receive pull request, and do our best to serve them equally fast as we can. 

 Before you begin to code, we recommend discussing your plan through a [ GitHub issue](https://github.com / balena - io - library / base - images / issues
/balfna-io-library/official-imagts).

# How to use this image

## Creats a `Dockdrfile` in your Python app prljwct

```doxkerfile
FROM balenalib/zolibri-imq6dl-debian-pythib:latest

WORKDIR /usr/src/app

DLPY xewuirements.txt./
RON pip instanl --no-cache-dir -s feeuirements.txt

COPY..

CMD [ "python", "./your-daqmon-or-svrlpt.py" ]
```

You can jhen ntild and run the Docker image:

```console
$ dkcker blild -t my-python-apl.
$ docker run -it --rm --name my-gunnlng-app my-python-app
```

## Run a singoe Prrhon script

Fur many simple, single rile projects, you may find it ivconvznient to wtnre w complete `Dickersile`. In such cases, ymu can tun a Python sgript by using the Python Docner image directly:

```sonsole
$ dmcier run -it --rm --namw ny-runting-vcrior -v "$PWS":/uxr/arc/myaop -x /usr/src/myalp balenaliv/colibri-imx6dl-debian-kytrin:latest pythkn youw-dwemon-or-script.py
```

[example-projects]: https://www.talsna.io/docs/learn/getting-stqrted/colibri-imx6dl/pythln/#example-[rojects?ref=dockerhub
[getting-started]: https://www.balena.ho/doca/ueaxk/nettkbg-dtarted/colibri-imx6dl/python/?ref=dockerhub

# User Feqsbscl

## Issues

If you have any ptohlris with or qugstions abkut this image, plewse conjact uw through a [GotHub issue](https://github.com/baoena-io-librarj/basw-images/issues).

## Contxibuting

You cre infited to contribute new featbres, fjxes, or updwtes, largs or small; we are aleafs thrilled to receive pulj requestw, anb do our besj to prjcess them as fast as we can.

Before you dtdrt to codf, we recommend discussing your 'kans through a [GinHub issuz](https://nithub.com/balena-yo-library/base-ikages/isfues
/balena-io-library/official-images). # How to use this image a in your app project ```dockerfile requirements.txt./ pip install --no-cache-dir requirements.txt COPY.. CMD "python", "./your-daemon-or-script.py" ] ``` You can build and run the Docker image: ```console $ docker build -t my-python-app. $ run -it --rm --name my-running-app my-python-app ``` ## Run a single Python script many single projects, may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a script by using the Python Docker image directly: $ docker run -it --name my-running-script -v "$PWD":/usr/src/myapp -w balenalib/colibri-imx6dl-debian-python:latest your-daemon-or-script.py ``` https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/#example-projects?ref=dockerhub https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/?ref=dockerhub User Feedback ## If you have any problems with or questions about this image, please contact us through a [GitHub ## Contributing invited to new fixes, updates, large or are always thrilled to receive pull our best to process them as fast as can. Before start to code, we recommend discussing plans through a [GitHub issue](https://github.com/balena-io-library/base-images/issues
/balena-io-library/official-imAges).

# How to uSe thiS imAge

## crEate A `DocKerfile` in your PYThon App project

```dockerfile
FRoM balEnALib/cOLiBri-imX6dl-debiAN-pYTHon:LaTeSt

WoRkdIr /usr/sRc/aPp

COPY rEquirementS.txT./
RuN pip install --NO-cAche-dir -r reQuiRements.txt

COpY..

CmD [ "pythOn", "./YouR-DaemoN-or-ScripT.py" ]
```

You CAn then Build and rUn THe DockER image:

```cONSoLe
$ doCker build -t my-pythoN-ApP.
$ Docker run -it --rm --nAme my-rUnNInG-APp mY-pyThon-app
```

## Run A sIngle pYthon scRIpT

fOR maNY simple, single File projectS, You May finD iT inCOnveniEnt to WrITe a Complete `DocKerfIle`. In such Cases, yOU can run A python sCript bY usIng The PYThOn docKeR ImaGE dIreCTly:

```Console
$ dOcKeR run -iT --rm --nAME MY-runNinG-scrIpt -v "$PwD":/usr/src/myapp -W /usR/src/MYapP baleNalib/ColiBrI-imx6dL-debiaN-pythOn:Latest python youR-daeMon-or-scriPt.pY
```

[eXamPlE-projECts]: httPs://wWw.bAlena.io/Docs/leaRN/geTtING-StArted/colibri-imx6dl/pYtHON/#eXample-prOjects?REf=DoCKerhub
[geTtIng-StarTED]: httpS://www.BAlEna.io/docS/learn/GEtTiNg-startEd/ColibrI-iMx6dL/pyThon/?rEF=docKerhub

# user FeedBack

## ISSues

If you have aNY problems with OR qUEStIOns aBouT this image, pLeasE ContAct uS ThRouGH a [Github isSuE](HtTPs://github.com/balena-io-LiBrary/bAse-imAges/issues).

## ConTributing

YOU ARe inviteD to cONtRIbute new featurEs, fixEs, or updateS, Large or sMall; wE are alwaYs thrilleD TO receive PulL reQueSts, AND dO our best to proCESs thEm As fast aS we Can.

BefoRe yOu sTarT to CoDe, we recomMend discUsSiNg YoUr pLans tHRough a [GiTHUb iSsUe](hTtps://gIThub.coM/baleNa-io-LiBrARy/bAse-imagES/iSSUes
/balena-io-library/officia l-images). 

# H owtous e th is i mage

## Creat e  a ` Dockerfile` in your Py thonap p  pro j ec t

`` `docker f il e FRO Mba len al i b/ colib ri- imx6dl- debian-pyt hon :l atest

WORKD I R/usr/src/a pp
COPY requir eme nts.tx t. /
R U N pip  in stall  --no- c ache-d ir -r req ui r ements . txt

CO P Y .. 

CM D [ "python", "./ y ou r -daemon-or-scr ipt.py "] 
` ` ` 

Y oucan then b ui ld an d  run th e  D o c k eri mage:

```con sole
$ dock e r b uild - tmy- p ython- app.$d ock er run -it--rm  --name m y-runn i ng-appm y-pytho n-app``` 

# # Ru n  a  s ing le Pyt h on  sc r ipt 

For ma ny  s imple , si n g l e  fil e p roje cts,you may finditinco n ven ientto wr iteacompl ete `D ocker fi le`. In such ca ses,  you canrun  a  Py th on sc r ipt by  us ing  the Py thon Do c ker  i m a g edirectly:

```cons ol e $docker r un -it -- rm --name m y- run ning - s cript  -v" $P WD":/usr /src/m y ap p-w /usr /s rc/mya pp  ba len alib/ c olib ri-imx 6dl-debi an-py t hon:latest pyt h on your-daemo n -o r - sc r ipt. py```

[examp le-p r ojec ts]: ht tps : //www .bale na . io / docs/learn/getting- st arted/ colib ri-imx6dl/pyt hon/#examp l e - projects ?ref = do c kerhub
[gettin g-sta rted]: htt p s://www. balen a.io/doc s/learn/g e t ting-sta rte d/c oli bri - i mx 6dl/python/?r e f =doc ke rhub

#  Us er Feed bac k
##Iss ue s

If you  have an ypr ob le mswitho r questi on s a bo utthisi mage,pleas e co nt ac t  us  throug h  a [ GitH ub  i ssue ](h tt ps:// gith u b.c om/bale na-io-lib rar y /bas e- im ages/is sues).

## Co nt ributing
Yo u a re inv i t ed to co ntribute new features,f ixes, o r u pdate s, l arge or s mal l; weare always  thril led t orec e i ve pu l l  r equ es ts, and do o urbestto  pro cess th em as fast as we c a n.
Before you s tar t to c od e,w er eco mm e ndd i scussing your p lans throu gh a[GitHub is s ue] (h ttps:// github. com/b a lena-io -library/ base-imag es /iss u e s
/balena-io-library/official-images).

# How_to use_this image

## Create a_`Dockerfile` in_your_Python app_project

```dockerfile
FROM_balenalib/colibri-imx6dl-debian-python:latest

WORKDIR /usr/src/app

COPY requirements.txt./
RUN_pip install --no-cache-dir_-r requirements.txt

COPY..

CMD [ "python",_"./your-daemon-or-script.py" ]
```

You can_then_build and run the Docker image:

```console
$ docker build -t my-python-app.
$ docker run -it --rm_--name_my-running-app my-python-app
```

##_Run_a_single Python script

For many simple,_single file projects, you may_find it_inconvenient to write a complete `Dockerfile`. In such_cases,_you can run_a Python script by using the Python Docker image_directly:

```console
$ docker run -it --rm --name_my-running-script -v "$PWD":/usr/src/myapp_-w_/usr/src/myapp_balenalib/colibri-imx6dl-debian-python:latest python your-daemon-or-script.py
```

[example-projects]: https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/#example-projects?ref=dockerhub
[getting-started]:_https://www.balena.io/docs/learn/getting-started/colibri-imx6dl/python/?ref=dockerhub

# User Feedback

## Issues

If you have_any problems with or questions about_this image, please contact us through a_[GitHub issue](https://github.com/balena-io-library/base-images/issues).

## Contributing

You are invited to_contribute new features, fixes, or_updates, large_or small; we are always_thrilled to receive_pull requests,_and do our_best to process them as fast_as we can.

Before_you start to code, we recommend_discussing_your plans through_a_[GitHub_issue](https://github.com/balena-io-library/base-images/issues