Commit 8eae7f36 authored by kaiyou's avatar kaiyou

Use the proper cli in the DOckerfile

parent 310e1f91
...@@ -10,4 +10,5 @@ USER amonit ...@@ -10,4 +10,5 @@ USER amonit
ENV AMONIT_CONFIG /amonit.yaml ENV AMONIT_CONFIG /amonit.yaml
CMD celery -A amonit worker -B -s /tmp/schedule ENTRYPOINT python -m amonit.cli
\ No newline at end of file CMD standalone
...@@ -25,7 +25,7 @@ def worker(): ...@@ -25,7 +25,7 @@ def worker():
def manager(worker=False): def manager(worker=False):
app = scheduler.Scheduler.get_app() app = scheduler.Scheduler.get_app()
app.scheduler.schedule(app) app.scheduler.schedule(app)
app.Beat().run() app.Beat(schedule="/tmp/schedule").run()
@cli.command() @cli.command()
...@@ -35,7 +35,7 @@ def standalone(): ...@@ -35,7 +35,7 @@ def standalone():
worker = app.Worker() worker = app.Worker()
thread = threading.Thread(target=worker.start) thread = threading.Thread(target=worker.start)
thread.start() thread.start()
app.Beat().run() app.Beat(schedule="/tmp/schedule").run()
@test.command() @test.command()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment