Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Add deploy info to a log file #58

Open
mamedin opened this issue Sep 24, 2020 · 0 comments
Open

Feature: Add deploy info to a log file #58

mamedin opened this issue Sep 24, 2020 · 0 comments

Comments

@mamedin
Copy link
Contributor

mamedin commented Sep 24, 2020

We were using in the shared sites' playbook this task:

     - name: "Update deploy log"
       become: "true"
       blockinfile:
         path: "/var/log/atom-deploy.log"
         insertafter: EOF
         marker: "-------"
         create: true
         content: |
           Installed {{ site }} on {{ ansible_ssh_host }}
           Revision: {{ latest_revision.stdout }} ( {{ atom_repository_version }} )
           Run by: {{ tower_user_name | default(lookup('env', 'USER')) }}
           Current date is: {{ ansible_date_time.iso8601 }}
       tags: "always"

Could be useful something like this for AWX and non AWX deploys.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant