Skip to content

Commit

Permalink
Smarter without a license.
Browse files Browse the repository at this point in the history
  • Loading branch information
robert-de-bock committed Feb 2, 2024
1 parent 86375e1 commit 3242e33
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ The default values for the variables are set in [`defaults/main.yml`](https://gi
tfe_image: "images.releases.hashicorp.com/hashicorp/terraform-enterprise:v202309-1"
# Paste the license of Terraform Enterprise here. It's a long string.
# If the license is not set, may tasks will be skipped, resulting in a non-working
# If the license is not set or empty, may tasks will be skipped, resulting in a non-working
# Terraform Enterprise instance. Not setting a license can help with testing.
# tfe_license: "XYZ123"
tfe_license: ""
# Configure a hostname, used to redirect HTTP(S) requests.
tfe_hostname: "tfe.example.com"
Expand Down
4 changes: 2 additions & 2 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
tfe_image: "images.releases.hashicorp.com/hashicorp/terraform-enterprise:v202309-1"

# Paste the license of Terraform Enterprise here. It's a long string.
# If the license is not set, may tasks will be skipped, resulting in a non-working
# If the license is not set or empty, may tasks will be skipped, resulting in a non-working
# Terraform Enterprise instance. Not setting a license can help with testing.
# tfe_license: "XYZ123"
tfe_license: ""

# Configure a hostname, used to redirect HTTP(S) requests.
tfe_hostname: "tfe.example.com"
Expand Down
1 change: 1 addition & 0 deletions handlers/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@
state: restarted
when:
- tfe_license is defined
- tfe_license != ""
3 changes: 3 additions & 0 deletions tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
password: "{{ tfe_license }}"
when:
- tfe_license is defined
- tfe_license != ""

- name: Create /etc/terraform-enterprise/certs
ansible.builtin.file:
Expand Down Expand Up @@ -69,6 +70,7 @@
mode: '0400'
when:
- tfe_license is defined
- tfe_license != ""
notify:
- Restart terraform-enterprise

Expand All @@ -92,3 +94,4 @@
enabled: true
when:
- tfe_license is defined
- tfe_license != ""

0 comments on commit 3242e33

Please sign in to comment.