plaintext
01/14/2021, 9:49 PMCODE:
- hosts: all
become: yes
become_user: root
tasks:
- name: Vault healthcheck
uri:
url: "<https://127.0.0.1:8080>"
follow_redirects: none
method: GET
validate_certs: 'no'
remote_src: yes
register: _result
- debug: msg="{{_result}}"
TASK [Gathering Facts] ******************************************************************************************************************************************************************************************
ok: [192.168.6.120]
TASK [Vault healthcheck] ****************************************************************************************************************************************************************************************
fatal: [192.168.6.120]: FAILED! => {"changed": false, "connection": "close", "content_length": "42", "content_type": "text/html; charset=utf-8", "date": "Thu, 14 Jan 2021 20:59:30 GMT", "elapsed": 0, "location": "<https://127.0.0.1:8080/setup>", "msg": "Status code was 307 and not [200]: HTTP Error 307: Temporary Redirect", "redirected": false, "status": 307, "url": "<https://127.0.0.1:8080>"}
If I use curl -L (to follow redirect) I got this:
automation@fleetdm:~$ curl -k -L <https://127.0.0.1:8080>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" href="/assets/bundle-d647bb374238130a2046.css">
<link rel="shortcut icon" href="/assets/favicon.ico">
<title>Fleet for osquery</title>
<script type="text/javascript">
var urlPrefix = "";
</script>
</head>
<body>
<div id="app"></div>
<script async defer src="/assets/bundle-4a09707c77216776a8be.js" onload="this.parentElement.removeChild(this)"></script>
<script>document.addEventListener("touchstart", function() {},false);</script>
</body>
</html>
So I set the follow_redirect to all in the ansible fleetdm.yml but when it's installing nginx I got this error:CptOfEvilMinions
01/14/2021, 9:52 PMfollow_redirects: none
to follow_redirects: yes
git pull
for the latest changesplaintext
01/15/2021, 2:50 PM