Commit 319ce53d authored by okhin's avatar okhin 🚴

Fixing the ownership of some directories

parent 1a61a90f
......@@ -2,7 +2,7 @@
- name: create a rp user
user:
append: yes
groups: [gitlab-runner, www-data]
groups: [www-data]
home: "{{ rp_path }}"
name: "{{ rp_unix_user }}"
state: present
......@@ -38,23 +38,26 @@
path: /run/uwsgi/app/rp/
owner: "{{ rp_unix_user }}"
group: www-data
mode: 0775
- block:
- name: create the directory for code and environment
file:
path: "{{ rp_path }}"
state: directory
group: gitlab-runner
mode: g+srw
- name: create the directory for code
file:
path: "{{ rp_source_path }}"
state: directory
group: www-data
mode: g+srw
recurse: yes
- block:
- name: unzip the rp code
unarchive:
src: "{{ rp_download_url }}"
dest: "{{ rp_path }}"
keep_newer: yes
remote_src: yes
mode: g+rw
mode: g+srw
owner: "{{ rp_unix_user }}"
group: gitlab-runner
group: www-data
- name: install python requirement
pip:
......@@ -69,6 +72,15 @@
virtualenv_python: python3
when: rp_debug
- name: setting proper permission for the virtualenv
file:
path: "{{ rp_path }}/env"
state: directory
follow: false
group: www-data
mode: g+srw
recurse: yes
- name: yarn install the application
yarn:
path: "{{ rp_source_path }}/"
......@@ -86,6 +98,9 @@
template:
src: templates/env.py.j2
dest: "{{ rp_source_path }}/project/settings/env.py"
owner: "{{ rp_unix_user }}"
group: www-data
mode: g+srw
- name: migrate the database
django_manage:
......@@ -111,5 +126,3 @@
template:
src: templates/vassals-rp.j2
dest: /etc/uwsgi-emperor/vassals/rp.ini
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