# ./env/bin/gunicorn\_start: 14: source: not found

**URL:** <https://forum.djangoproject.com/t/env-bin-gunicorn-start-14-source-not-found/34870>\
**Category:** Deployment\
**Created:** [September 18, 2024, 1:27am UTC](https://forum.djangoproject.com/t/env-bin-gunicorn-start-14-source-not-found/34870 "2024-09-18T01:27:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Starter](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/starter/32/23977_2.png) [@Starter](https://forum.djangoproject.com/u/Starter)\
**Post date:** [September 18, 2024, 1:27am UTC](https://forum.djangoproject.com/t/env-bin-gunicorn-start-14-source-not-found/34870/1 "2024-09-18T01:27:53Z")

</div>

I am new to django and following this video [https://www.youtube.com/watch?v=Td3lirXIeRI](https://www.youtube.com/watch?v=Td3lirXIeRI)

```auto
#!/bin/sh

NAME='project2'
DJANGODIR=/webapps/project2/project2
SOCKFILE=/webapps/project2/run/gunicorn.sock
USER=project2user
GROUP=webapps
NUM_WORKERS=3
DJANGO_SETTINGS_MODULE=project2.settings
DJANGO_WSGI_MODULE=project2.wsgi
TIMEOUT=120

cd $DJANGODIR
source ../env/bin/activate
export DJANGO_SETTINGS_MODULE=$DJANGO_SETTINGS_MODULE
export PYTHONPATH=$DJANGODIR:$PYTHONPATH

RUNDIR=$(dirname $SOCKFILE)
test -d $RUNDIR || mkdir -p $RUNDIR

exec ../env/bin/gunicorn ${DJANGO_WSGI_MODULE}:application \
--name $NAME \
--workers $NUM_WORKERS \
--timeout $TIMEOUT \
--user=$USER \
--group=$GROUP \
--bind=unix:$SOCKFILE\
--log-level=debug \
--log-file =-

```

**Error**

```auto
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps/project2# ./env/bin/gunicorn_start
./env/bin/gunicorn_start: 14: source: not found

```

File Structure

```auto
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps# cd project2
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps/project2# cd env
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps/project2/env# cd bin
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps/project2/env/bin# ls
Activate.ps1 activate.fish bugscanner fonttools numpy-config pyftmerge python3.12
__pycache__ atm django-admin gunicorn pip pyftsubset sqlformat
activate automium_web.bat f2py gunicorn_start pip3 python ttx
activate.csh automium_web_pypi.py flask normalizer pip3.12 python3

```

```auto
(env) root@ubuntu-s-1vcpu-2gb-nyc1-01:/webapps/project2/project2/project2# ls
__init__.py __pycache__ asgi.py requirements.txt settings.py settings_dev.py urls.py wsgi.py

```

---

<div class="post-metadata">

**Author:** ![KenWhitesell](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/kenwhitesell/32/280_2.png) [@KenWhitesell](https://forum.djangoproject.com/u/KenWhitesell)\
**Post date:** [September 18, 2024, 1:55am UTC](https://forum.djangoproject.com/t/env-bin-gunicorn-start-14-source-not-found/34870/2 "2024-09-18T01:55:58Z")

</div>

Welcome @Starter !

The default shell in some distros is dash, which doesn’t support the `source` command. You should specify `/bin/bash` or some other shell supporting the `source` command.

Also, rather than trying to figure out the relative paths, I’d change the `source` statement to use the absolute path, `/webapps/project2/env/bin/activate`.

---

<div class="post-metadata">

**Author:** ![Starter](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/starter/32/23977_2.png) [@Starter](https://forum.djangoproject.com/u/Starter)\
**Post date:** [September 18, 2024, 2:07am UTC](https://forum.djangoproject.com/t/env-bin-gunicorn-start-14-source-not-found/34870/3 "2024-09-18T02:07:38Z")

</div>

Thank you! Specifying /bin/bash solved the problem.
