Skip to content

Commit

Permalink
Merge pull request #1 from clouddrove/fix
Browse files Browse the repository at this point in the history
resolve bug
  • Loading branch information
anmolnagpal committed Sep 16, 2019
2 parents 5babc9f + 31834e2 commit 2cc922d
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 17 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,12 +97,12 @@ Followiing things includes in this role:
```yaml
pritunl_version: "latest"
pritunl_path: "/opt/pritunl"
pritunl_mongo_path: "/opt/pritunl/mongo"
pritunl_log: "/var/log/pritunl.log"
pritunl_user: pritunl
pritunl_group: pritunl
pritunl_mongo_user: mongo
pritunl_mongo_group: mongo
mongo_path: "/opt/pritunl/mongo"
mongo_user: mongo
mongo_group: mongo
```


Expand Down
6 changes: 3 additions & 3 deletions README.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,12 @@ variables: |-
```yaml
pritunl_version: "latest"
pritunl_path: "/opt/pritunl"
pritunl_mongo_path: "/opt/pritunl/mongo"
pritunl_log: "/var/log/pritunl.log"
pritunl_user: pritunl
pritunl_group: pritunl
pritunl_mongo_user: mongo
pritunl_mongo_group: mongo
mongo_path: "/opt/pritunl/mongo"
mongo_user: mongo
mongo_group: mongo
```
# How to install project
Expand Down
9 changes: 5 additions & 4 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@ pritunl_version: "latest"

# Pritunl settings
pritunl_path: "/opt/pritunl"
pritunl_mongo_path: "/opt/pritunl/mongo"
pritunl_log: "/var/log/pritunl.log"

pritunl_user: pritunl
pritunl_group: pritunl
pritunl_mongo_user: mongo
pritunl_mongo_group: mongo

# Mongo settings
mongo_path: "/opt/pritunl/mongo"
mongo_user: mongo
mongo_group: mongo
6 changes: 3 additions & 3 deletions tasks/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
file:
path: "{{ item|safe|trim }}"
state: directory
owner: "{{ pritunl_mongo_user }}"
group: "{{ pritunl_mongo_group }}"
owner: "{{ mongo_user }}"
group: "{{ mongo_group }}"
mode: 0755
recurse: true
with_items:
- "{{ pritunl_mongo_path }}"
- "{{ mongo_path }}"

- name: transfer pritunl.conf
template:
Expand Down
6 changes: 3 additions & 3 deletions tasks/users.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@

- name: setup group
group:
name: "{{ pritunl_mongo_group }}"
name: "{{ mongo_group }}"
system: false

- name: setup user
user:
name: "{{ pritunl_mongo_user }}"
name: "{{ mongo_user }}"
system: false
group: "{{ pritunl_mongo_group }}"
group: "{{ mongo_group }}"
2 changes: 1 addition & 1 deletion templates/pritunl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ docker rm -f -v pritunl || :

docker run -u root --net=host --rm --name pritunl \
-v "{{ pritunl_path }}":/var/lib/pritunl \
-v "{{ pritunl_mongo_path }}":/var/lib/mongodb \
-v "{{ mongo_path }}":/var/lib/mongodb \
-v "{{ pritunl_path }}/pritunl.conf":/etc/pritunl.conf \
-v "{{ pritunl_log }}":{{ pritunl_log }} \
clouddrove/pritunl:{{ pritunl_version }}

0 comments on commit 2cc922d

Please sign in to comment.