# Ensure you are running in the correct environment or set the correct configuration file with -c

**URL:** <https://forum.gitea.com/t/ensure-you-are-running-in-the-correct-environment-or-set-the-correct-configuration-file-with-c/4957>\
**Category:** Install/Maintain/Configure\
**Created:** [March 31, 2022, 2:35pm UTC](https://forum.gitea.com/t/ensure-you-are-running-in-the-correct-environment-or-set-the-correct-configuration-file-with-c/4957 "2022-03-31T14:35:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![JochenW](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.gitea.com/jochenw/32/5046_2.png) [@JochenW](https://forum.gitea.com/u/JochenW)\
**Post date:** [March 31, 2022, 2:35pm UTC](https://forum.gitea.com/t/ensure-you-are-running-in-the-correct-environment-or-set-the-correct-configuration-file-with-c/4957/1 "2022-03-31T14:35:01Z")

</div>

Hi,

using the Dockerfile below, I get the error message, which is even further below. My guess for the reason is, that the app.ini file doesn’t yet exist. So, how would I get it created?

Docker file:

```auto
FROM gitea/gitea:1.16.5
EXPOSE 3000 22
RUN apk add mlocate emacs runuser
RUN GITEA __security__ INSTALL_LOCK=true runuser -u git -- /usr/local/bin/gitea -c /data/gitea/conf/app.ini admin user create --admin --username root -password manage --email noreply@softwareag.com

```

Output from “docker build”:

```auto
> [3/3] RUN GITEA __security__ INSTALL_LOCK=true runuser -u git -- /usr/local/bin/gitea -c /data/gitea/conf/app.ini admin user create --admin --username root -password manage --email noreply@softwareag.com:
#7 1.091 2022/03/31 14:29:26 ...s/setting/setting.go:587:loadFromConf() [F] Unable to find configuration file: "/data/gitea/conf/app.ini".
#7 1.091 Ensure you are running in the correct environment or set the correct configuration file with -c.
------
executor failed running [/bin/sh -c GITEA __security__ INSTALL_LOCK=true runuser -u git -- /usr/local/bin/gitea -c /data/gitea/conf/app.ini admin user create --admin --username root -password manage --email noreply@mycompany.com]: exit code: 1

```
