Skip to content

Commit b4143ce

Browse files
committed
install from package method
1 parent 12b11f0 commit b4143ce

4 files changed

Lines changed: 15 additions & 1 deletion

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
| Feature | Supported |
1010
| -------------------- | --------- |
1111
| From source ||
12+
| Using package ||
1213
| Using Docker run ||
1314
| Using Docker Compose ||
1415

defaults/main.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
pyproxy:
2-
# "compose", "docker", "source"
2+
# "compose", "docker", "source", "package"
33
deploy_method: "compose"
44

55
# Compose
@@ -58,6 +58,10 @@ pyproxy:
5858
service_name: "pyproxy"
5959
ssl_inspect_ca_folder: certs/
6060

61+
# Package
62+
package:
63+
version: "latest" # 0.4.2
64+
6165
# These variables configure the config.ini file that will be copied to the machine.
6266
# You must configure either a volume for the "compose" or "docker" method, or an argument for the "source" method.
6367
config:

tasks/install_from_package.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
- name: "Install pyproxytools package : {{ pyproxy.package.version }}"
2+
pip:
3+
name: "pyproxytools{{ '==' + pyproxy.package.version if pyproxy.package.version != 'latest' else '' }}"
4+
state: present
5+
extra_args: --break-system-packages

tasks/main.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,7 @@
99
- name: Include install from compose
1010
ansible.builtin.include_tasks: install_from_compose.yml
1111
when: pyproxy.deploy_method == "compose"
12+
13+
- name: Include install from package
14+
ansible.builtin.include_tasks: install_from_package.yml
15+
when: pyproxy.deploy_method == "package"

0 commit comments

Comments
 (0)