Commit d0636eff authored by Roman Shishkin's avatar Roman Shishkin

Фикс контейнера celery

parent ff6c761b
BROKER_URL = 'redis://127.0.0.1:6589/1'
CELERY_RESULT_BACKEND = 'redis://127.0.0.1:6589/2'
CELERY_IMPORTS = ("tasks",)
CELERY_TASK_SERIALIZER = 'json'
CELERY_RESULT_SERIALIZER = 'json'
CELERY_ACCEPT_CONTENT = ['json']
CELERY_TIMEZONE = 'Europe/Moscow'
CELERY_ENABLE_UTC = True
daemonize no
dir /storage
save 1 10
maxclients 100
port 6589
\ No newline at end of file
......@@ -5,7 +5,7 @@
--project echoes \
--type production \
--blobs "frontend" \
--containers "python" \
--containers "python redis celery" \
--destination /home/ci/lithos/images \
--server lentach.uwtech.org \
--port 2222 \
......
<div class="col-md-12">
<header class="header">
<img class="header__image" src="/static/images/true_logo.png" alt="ЛЕНТАЧ">
<h1>Предложите нам новость!</h1>
<h1>Предложи нам новость!</h1>
</header>
<form>
<div class="input-group">
<label for="description">
<label for="summary">
Описание:
</label>
<input type="text" id="description" class="form-control" placeholder="Краткое описание вашей новости">
<input type="text" id="summary" class="form-control" placeholder="Краткое описание вашей новости">
</div>
<div class="input-group">
......
......@@ -19,6 +19,10 @@ textarea {
display: inline-block;
}
.input-group label {
font-size: 16pt;
font-weight: bold;
}
.user-row {
height: 64px;
}
......
user-id: 1
group-id: 1
volumes:
/state: !Statedir {}
fileno-limit: 50ki
memory-limit: 512Mi
cpu-shares: 1024
environ:
PYTHONPATH: /config/celeryconfig:/app
CELERY_CONFIG_MODULE: cfg
CELERY_MAILER_HOST: localhost
CELERY_MAILER_PORT: 25
workdir: /app
executable: /usr/bin/celery
arguments:
- worker
- --pool=solo
\ No newline at end of file
kind: Command
user-id: 1
group-id: 1
volumes:
/state: !Statedir {}
/storage: !Persistent
path: /storage/redis
mkdir: true
mode: 0o700
user: 1
group: 1
fileno-limit: 50ki
memory-limit: 256Mi
cpu-shares: 128
interactive: true
executable: /usr/bin/redis-cli
arguments: []
\ No newline at end of file
user-id: 1
group-id: 1
volumes:
/state: !Statedir {}
/storage: !Persistent
path: /storage/redis
mkdir: true
mode: 0o700
user: 1
group: 1
fileno-limit: 50ki
memory-limit: 2Gi
cpu-shares: 1024
executable: /usr/bin/redis-server
arguments:
- /config/redis.conf
\ No newline at end of file
......@@ -10,8 +10,6 @@ pony==0.7.2
pytz==2016.10
requests==2.12.4
speaklater==1.3
py-vkontakte==5.53.4
webassets==0.12.0
Werkzeug==0.11.15
numpy
vklancer
......@@ -8,7 +8,9 @@ _templates:
- !Copy
source: /work/lithos/production
path: /lithos
- !Copy
source: /work/config/production
path: /config
- &host_resolution
- !EnsureDir /state
- !Sh |
......@@ -37,7 +39,6 @@ containers:
python:
setup:
- !Container _base_alpine
- !Install [[email protected]]
- !PipConfig
dependencies: true
- !Py3Requirements "requirements.txt"
......@@ -66,6 +67,7 @@ containers:
dependencies: true
- !Py3Install
- celery[redis]
- numpy
- !EnsureDir /app
volumes:
<<: *local_volumes
......@@ -133,6 +135,28 @@ containers:
resolv-conf-path: /state/resolv.conf
hosts-file-path: /state/hosts
redis-production:
setup:
- !Container redis
- !*Unpack
- *production_stuff
- *host_resolution
resolv-conf-path: /state/resolv.conf
hosts-file-path: /state/hosts
celery-production:
setup:
- !Container celery
- !*Unpack
- *production_stuff
- *host_resolution
- !Copy
source: /work/celery_tasks
path: /app
- !Sh python3 -m compileall /app
resolv-conf-path: /state/resolv.conf
hosts-file-path: /state/hosts
commands:
flask: &flask !Command
container: python
......
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