Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use docker for #784

Closed
1n5aN1aC opened this issue Dec 21, 2024 · 4 comments
Closed

How to use docker for #784

1n5aN1aC opened this issue Dec 21, 2024 · 4 comments
Labels
help wanted Issues that need assistance from volunteers

Comments

@1n5aN1aC
Copy link

Not exactly a bug, but probably a lack of understanding, and unable to find direction in the documentation.

I wished to start with something very similar to the built-in example, (ds:example) so I started the docker container using docker-compose:

  onlyoffice:
    container_name: onlyoffice
    image: onlyoffice/documentserver
    restart: always
    ports:
      - "1005:80"
    environment:
      JWT_SECRET: example_jwt_secret
    volumes:
      - /etc/localtime:/etc/localtime:ro
      - /docker/onlyoffice/files:/var/lib/onlyoffice
      - /docker/onlyoffice/db:/var/lib/postgresql
      - /docker/onlyoffice/fonts:/usr/share/fonts

And I can successfully access the web interface, and I saw the instructions to start the examples:
sudo docker exec 03610350a9a6 sudo supervisorctl start ds:example
or
sudo docker exec 03610350a9a6 sudo sed 's,autostart=false,autostart=true,' -i /etc/supervisor/conf.d/ds-example.conf

I run those commands and they work. So from that example, I assume the correct way to create my own services is to create my own file with my own content in that directory.

However, the biggest thing I do not understand is how to make that service run permanently. As an example, lets say I just want to use the example permanently. (Only as an example)

  • I cannot simple do as the example says, as that will be lost upon upgrading the container.
  • I tried mapping the /etc/supervisor/conf.d folder to a local folder, putting my examples in it, and setting autostart=true. Upon restarting the container, nothing happened, and the logs seem to indicate it found no services to start. Even though I confirmed the files are in the correct location inside the container.

So what is the intended way to actually use this container?

Thanks!!

Host Operating System:
Linux EXAMPLE 6.11.10-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.11.10-1 (2024-11-23) x86_64 GNU/Linux
Docker version 26.1.5+dfsg1, build a72d7cd

@igwyd
Copy link
Member

igwyd commented Dec 26, 2024

Hello, that's because our application and services are configured to run in container when create image. I don’t know the details, but I guess that in your case you need to build your own container, for example, based on ours and configure your service. We will put the label "need help" because the question is beyond the scope of documentserver.

@Rita-Bubnova Rita-Bubnova added the help wanted Issues that need assistance from volunteers label Dec 26, 2024
@1n5aN1aC
Copy link
Author

Hmm, alright.

So am I correct in understanding then that this container has no official way of running a specified service permanently? The user is expected to build their own container from the available sources and make the desired modifications at that level?

@igwyd
Copy link
Member

igwyd commented Dec 27, 2024

Yes, this container has way to run only own services, not custom.

The user is expected to build their own container from the available sources and make the desired modifications at that level?

You can create your app as you wish. It could be based on this container, a separeted container with an application and connect via network, not container etc . There could be many optios.

@1n5aN1aC
Copy link
Author

1n5aN1aC commented Jan 4, 2025

Thank you for explaining.

@1n5aN1aC 1n5aN1aC closed this as completed Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Issues that need assistance from volunteers
Projects
None yet
Development

No branches or pull requests

3 participants