# Using the Nextcloud command-line interface

**URL:** <https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851>\
**Category:** Docker Hub\
**Tags:** docker\
**Created:** [January 3, 2025, 5:30pm UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851 "2025-01-03T17:30:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jjroby1993](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/jjroby1993/32/55307_2.png) [@jjroby1993](https://forums.docker.com/u/jjroby1993)\
**Post date:** [January 3, 2025, 5:30pm UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851/1 "2025-01-03T17:30:21Z")

</div>

```auto
 docker exec --user www-data CONTAINER_ID php occ

```

doesn’t seem to work and outputs the Usage Doc.

How can I edit the php config file in the image?

---

<div class="post-metadata">

**Author:** ![rimelek](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/rimelek/32/41602_2.png) [@rimelek](https://forums.docker.com/u/rimelek)\
**Post date:** [January 3, 2025, 5:44pm UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851/2 "2025-01-03T17:44:06Z")

</div>

Please, explain why should this work. occ is not a php file I assume. I have no idea what it should do.

---

<div class="post-metadata">

**Author:** ![bluepuma77](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/bluepuma77/32/32688_2.png) [@bluepuma77](https://forums.docker.com/u/bluepuma77)\
**Post date:** [January 5, 2025, 9:28am UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851/3 "2025-01-05T09:28:01Z")

</div>

It seems `occ` is a PHP script, from the [doc](https://docs.nextcloud.com/server/stable/admin_manual/configuration_server/occ_command.html):

> Running `occ` with no options lists all commands and options,

---

<div class="post-metadata">

**Author:** ![rimelek](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/rimelek/32/41602_2.png) [@rimelek](https://forums.docker.com/u/rimelek)\
**Post date:** [January 5, 2025, 9:38am UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851/4 "2025-01-05T09:38:24Z")

</div>

So it seems @bluepuma77 solved it for you by reading the documentation that shows the command requires arguments which you did not add. But the “Usage docs” you mentioned that was showed by the script must have shared the same info

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/docker/original/3X/d/4/d4fbccd46c81bfcffe9822e20e17736d946fa821.png) [@system](https://forums.docker.com/u/system)\
**Post date:** [January 15, 2025, 9:39am UTC](https://forums.docker.com/t/using-the-nextcloud-command-line-interface/145851/5 "2025-01-15T09:39:12Z")

</div>

Closed on January 15, 2025, 9:39am UTC

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.
