Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kolla Ansible
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Very Demiurge Very Mindful
Kolla Ansible
Commits
f0d8b129
Commit
f0d8b129
authored
8 years ago
by
Jenkins
Committed by
Gerrit Code Review
8 years ago
Browse files
Options
Downloads
Plain Diff
Merge "Only enabled services log files"
parents
ea7b2682
3bd180f8
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
ansible/roles/common/tasks/config.yml
+26
-25
26 additions, 25 deletions
ansible/roles/common/tasks/config.yml
ansible/roles/common/templates/cron.json.j2
+23
-23
23 additions, 23 deletions
ansible/roles/common/templates/cron.json.j2
with
49 additions
and
48 deletions
ansible/roles/common/tasks/config.yml
+
26
−
25
View file @
f0d8b129
...
@@ -65,29 +65,30 @@
...
@@ -65,29 +65,30 @@
-
name
:
Copying over cron logrotate config files
-
name
:
Copying over cron logrotate config files
template
:
template
:
src
:
"
cron-logrotate-{{
item
}}.conf.j2"
src
:
"
cron-logrotate-{{
item.name
}}.conf.j2"
dest
:
"
{{
node_config_directory
}}/cron/logrotate/{{
item
}}.conf"
dest
:
"
{{
node_config_directory
}}/cron/logrotate/{{
item.name
}}.conf"
when
:
item.enabled | bool
with_items
:
with_items
:
-
"
ansible"
-
{
name
:
"
ansible"
,
enabled
:
"
yes"
}
-
"
aodh"
-
{
name
:
"
aodh"
,
enabled
:
"
{{
enable_aodh
}}"
}
-
"
barbican"
-
{
name
:
"
barbican"
,
enabled
:
"
{{
enable_barbican
}}"
}
-
"
cinder"
-
{
name
:
"
cinder"
,
enabled
:
"
{{
enable_cinder
}}"
}
-
"
cloudkitty"
-
{
name
:
"
cloudkitty"
,
enabled
:
"
{{
enable_cloudkitty
}}"
}
-
"
glance"
-
{
name
:
"
glance"
,
enabled
:
"
{{
enable_glance
}}"
}
-
"
global"
-
{
name
:
"
global"
,
enabled
:
"
yes"
}
-
"
gnocchi"
-
{
name
:
"
gnocchi"
,
enabled
:
"
{{
enable_gnocchi
}}"
}
-
"
haproxy"
-
{
name
:
"
haproxy"
,
enabled
:
"
{{
enable_haproxy
}}"
}
-
"
heat"
-
{
name
:
"
heat"
,
enabled
:
"
{{
enable_heat
}}"
}
-
"
keepalived"
-
{
name
:
"
keepalived"
,
enabled
:
"
{{
enable_haproxy
}}"
}
-
"
keystone"
-
{
name
:
"
keystone"
,
enabled
:
"
{{
enable_keystone
}}"
}
-
"
magnum"
-
{
name
:
"
magnum"
,
enabled
:
"
{{
enable_magnum
}}"
}
-
"
manila"
-
{
name
:
"
manila"
,
enabled
:
"
{{
enable_manila
}}"
}
-
"
mariadb"
-
{
name
:
"
mariadb"
,
enabled
:
"
{{
enable_mariadb
}}"
}
-
"
mistral"
-
{
name
:
"
mistral"
,
enabled
:
"
{{
enable_mistral
}}"
}
-
"
murano"
-
{
name
:
"
murano"
,
enabled
:
"
{{
enable_murano
}}"
}
-
"
neutron"
-
{
name
:
"
neutron"
,
enabled
:
"
{{
enable_neutron
}}"
}
-
"
nova"
-
{
name
:
"
nova"
,
enabled
:
"
{{
enable_nova
}}"
}
-
"
rabbitmq"
-
{
name
:
"
rabbitmq"
,
enabled
:
"
{{
enable_rabbitmq
}}"
}
-
"
senlin"
-
{
name
:
"
senlin"
,
enabled
:
"
{{
enable_senlin
}}"
}
-
"
swift"
-
{
name
:
"
swift"
,
enabled
:
"
{{
enable_swift
}}"
}
-
"
watcher"
-
{
name
:
"
watcher"
,
enabled
:
"
{{
enable_watcher
}}"
}
This diff is collapsed.
Click to expand it.
ansible/roles/common/templates/cron.json.j2
+
23
−
23
View file @
f0d8b129
{% set cron_cmd = 'cron -f' if kolla_base_distro in ['ubuntu', 'debian'] else 'crond -s -n' %}
{% set cron_cmd = 'cron -f' if kolla_base_distro in ['ubuntu', 'debian'] else 'crond -s -n' %}
{% set services = [
{% set services = [
"
ansible
"
,
( '
ansible
', 'yes' )
,
"
aodh
"
,
( 'aodh', enable_
aodh
)
,
"
barbican
"
,
( 'barbican', enable_
barbican
)
,
"
cinder
"
,
( 'cinder', enable_
cinder
)
,
"
cloudkitty
"
,
( 'cloudkitty', enable_
cloudkitty
)
,
"
glance
"
,
( 'glance', enable_
glance
)
,
"
gnocchi
"
,
( '
gnocchi
', enable_gnocchi )
,
"
haproxy
"
,
( '
haproxy
', enable_haproxy )
,
"
heat
"
,
( 'heat', enable_
heat
)
,
"
keepalived
"
,
( '
keepalived
', enable_haproxy )
,
"
keystone
"
,
( 'keystone', enable_
keystone
)
,
"
magnum
"
,
( 'magnum', enable_
magnum
)
,
"
manila
"
,
( 'manila', enable_
manila
)
,
"
mariadb
"
,
( '
mariadb
', enable_mariadb )
,
"
mistral
"
,
( '
mistral
', enable_mistral )
,
"
murano
"
,
( 'murano', enable_
murano
)
,
"
neutron
"
,
( '
neutron
', enable_neutron )
,
"
nova
"
,
( 'nova', enable_
nova
)
,
"
rabbitmq
"
,
( 'rabbitmq', enable_
rabbitmq
)
,
"
senlin
"
,
( 'senlin', enable_
senlin
)
,
"
swift
"
( '
swift
', enable_swift )
] %}
] %}
{
{
"command": "{{ cron_cmd }}",
"command": "{{ cron_cmd }}",
...
@@ -31,13 +31,13 @@
...
@@ -31,13 +31,13 @@
"owner": "root",
"owner": "root",
"perm": "0644"
"perm": "0644"
},
},
{% for service in services %}
{% for service
, enabled
in services
if enabled | bool
%}
{
{
"source": "{{ container_config_directory }}/logrotate/{{ service }}.conf",
"source": "{{ container_config_directory }}/logrotate/{{ service }}.conf",
"dest": "/etc/logrotate.d/{{ service }}.conf",
"dest": "/etc/logrotate.d/{{ service }}.conf",
"owner": "root",
"owner": "root",
"perm": "0644"
"perm": "0644"
}{
%
if not loop.last
%},{% endif %
}
}{
{ ','
if not loop.last
else '' }
}
{% endfor %}
{% endfor %}
]
]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment