We’re rewarding the question askers & reputations are being recalculated! Read more.

New answers tagged

3

I'm looking this fact: I have an ASP.NET Core 3.0 application for which I have a full CI/CD setup in Azure DevOps. The Application is hosted on a Ubuntu 18.04 server machine. Therefore I can safely assume that you are developing ASP.NET Core 3.0 app to be hosted in Ubuntu. Any .NET Core 3.0 (or later) application means that you should rely on the dotnet ...


1

I have a solution on that way : --- - hosts: hostnametest tasks: - name: we take swap space used (megabytes) shell : free -m | grep Swap | awk '{print $3}' register: swap_used - name: Turn off swap shell: "swapoff -a" when: (swap_used.stdout_lines[0] | int) > 100 - name: Turn on swap shell: "swapon -a" when: (...


3

Apologies for not directly answering your question, but by the sounds of your question, you are trying to build an update management system to mitigate the threats of vulnerable operating system components and tools having unpatched vulnerabilities which expose you to risk. This functionality is actually already available for both Windows and Linux via ...


0

If you have ssh access from the Jenkins machine to the HAProxy machine, you could run an Ansible task: ansible -i ha-inventory.ini ha-servers -m service -a name=haproxy state=restarted Of course you could also have Jenkins do a simple ssh : for server in ${server_list} ; do ssh server 'sudo service haproxy restart' ; done For both of these, you would ...


2

I suspect what is happening here is you are trying to insert the private key into the authorized_keys file, which is invalid as only the public key is required on the target machine. What you need to do is extract the public key from the private key: - name: Generate an OpenSSL public key with a passphrase protected private key openssl_publickey: ...


2

You can certainly do this through a handler or task, but first you need to generate the trigger conditions. The swap space is in the Ansible facts that are returned when setup: is run. From the Ansible docs: Facts These are variables that contain information pertinent to the current host (inventory_hostname). They are only available if gathered first....


Top 50 recent answers are included