Merge "gerrit: don't chown mariadb container directory"

This commit is contained in:
Zuul 2021-11-05 09:25:17 +00:00 committed by Gerrit Code Review
commit 3da6615b36

@ -285,16 +285,14 @@
when: gerrit_redirect_vhost is defined when: gerrit_redirect_vhost is defined
notify: gerrit Reload apache2 notify: gerrit Reload apache2
- name: Start gerrit # NOTE(ianw) This deliberately does not set owner/group/mode, as the
include_tasks: start.yaml # mariadb container chowns this directory to be owned by a
# container-internal user and drops root privileges. We don't want to
# reset this from outside the container.
- name: Setup reviewdb directory for mariadb - name: Setup reviewdb directory for mariadb
file: file:
state: directory state: directory
path: /home/gerrit2/reviewdb path: /home/gerrit2/reviewdb
owner: root
group: root
mode: 0755
- name: Set up root mariadb conf file - name: Set up root mariadb conf file
template: template:
@ -302,6 +300,9 @@
dest: /root/.gerrit_db.cnf dest: /root/.gerrit_db.cnf
mode: 0400 mode: 0400
- name: Start gerrit
include_tasks: start.yaml
- name: Set up cron job to optmize git repos - name: Set up cron job to optmize git repos
cron: cron:
name: optmize-git-repos name: optmize-git-repos