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

OpenEats Doesn't Auto-Start at System Boot/Restart #58

Closed
jnikolich opened this issue Sep 26, 2018 · 2 comments
Closed

OpenEats Doesn't Auto-Start at System Boot/Restart #58

jnikolich opened this issue Sep 26, 2018 · 2 comments
Assignees

Comments

@jnikolich
Copy link

jnikolich commented Sep 26, 2018

(This isn't so much an issue, as a documentation enhancement request)

It appears that, by default, OpenEats will not auto-start whenever the Docker host is booted, and/or when Docker is fired up.

I found that I could cause auto-starting to happen correctly (at least for me) with the following definitions in my docker-prod.override.yml file:

docker-prod.override.yml

version: '2.3'
services:
  nginx:
    ports:
        - "8000:80"
    restart: always
  api:
    restart: always
  web:
    restart: on-failure
  db:
    restart: always

Notes/Comments

  1. The ports: stanza for nginx represents what I need in my system. Obviously, you'll want to customize this to your particular needs, assuming you require it at all.
  2. I found that under normal circumstances, the web container appears to be a "run-once" kind of thing. When you start OpenEats it will fire up, and terminate (presumally successfully). As this seems to be desired behaviour I set it to restart: on-failure instead of always as is done for the other containers.

Submitted in the hopes that this helps others looking to implement similar auto-start behaviour.

@jnikolich jnikolich changed the title OpenEats Doesn't Auto-Start at ystem boot/restart OpenEats Doesn't Auto-Start at System Boot/Restart Sep 26, 2018
@RyanNoelk
Copy link
Member

👍 I'll work on adding this to the documentation.

As for your comment about the web container, it's job is to generate a js bundle that nginx will serve. It saves the public content to a docker volume then exits when it's done. So your restart on-failure is correct.

@RyanNoelk RyanNoelk self-assigned this Nov 11, 2018
@RyanNoelk
Copy link
Member

I added this to the documentation: 05dbabd

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants