File tree Expand file tree Collapse file tree 3 files changed +36
-3
lines changed Expand file tree Collapse file tree 3 files changed +36
-3
lines changed Original file line number Diff line number Diff line change 19
19
dest : /opt/kayobe/containers/pulp/settings.py
20
20
mode : 0644
21
21
become : true
22
+
23
+ - name : Configure TLS for local Pulp
24
+ when : pulp_enable_tls
25
+ become : true
26
+ block :
27
+ - name : Ensure /opt/kayobe/containers/pulp/certs exists
28
+ file :
29
+ path : " /opt/kayobe/containers/pulp/certs"
30
+ state : directory
31
+
32
+ - name : Copy TLS cert and key into container directory
33
+ template :
34
+ src : " {{ item.src }}"
35
+ dest : " /opt/kayobe/containers/pulp/certs/{{ item.dest }}"
36
+ mode : 0644
37
+ become : true
38
+ loop :
39
+ - src : " {{ pulp_cert_path }}"
40
+ dest : ' pulp_webserver.crt'
41
+ - src : " {{ pulp_key_path }}"
42
+ dest : ' pulp_webserver.key'
Original file line number Diff line number Diff line change 1
1
---
2
2
# ##############################################################################
3
- # Local Pulp access credentials
3
+ # Local Pulp server configuration
4
4
5
5
# Base URL of the local Pulp service.
6
6
# Default uses the seed node's IP on the admin network.
7
- pulp_url : " http://{{ admin_oc_net_name | net_ip(groups['seed'][0]) }}:80"
7
+ pulp_url : " {{ 'https' if pulp_enable_tls else 'http' }}://{{ admin_oc_net_name | net_ip(groups['seed'][0]) }}:80"
8
+
9
+ # Whether to enable TLS for Pulp.
10
+ pulp_enable_tls : false
11
+
12
+ # Path to a TLS certificate to use when TLS is enabled.
13
+ # pulp_cert_path:
14
+
15
+ # Path to a TLS key to use when TLS is enabled.
16
+ # pulp_key_path:
17
+
18
+ # ##############################################################################
19
+ # Local Pulp access credentials
8
20
9
21
# Credentials used to access the local Pulp REST API.
10
22
pulp_username : admin
Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ seed_pulp_container:
96
96
image : pulp/pulp
97
97
pre : " {{ kayobe_config_path }}/containers/pulp/pre.yml"
98
98
post : " {{ kayobe_config_path }}/containers/pulp/post.yml"
99
- tag : " 3.16"
99
+ tag : " {{ ' 3.16-https' if pulp_enable_tls else '3.16' }} "
100
100
network_mode : host
101
101
volumes :
102
102
- /opt/kayobe/containers/pulp:/etc/pulp
You can’t perform that action at this time.
0 commit comments