Audit from Automate

Hi everyone,

Does anyone know how to create an entry to the audit log from a ManageIQ Automate method? I’m trying to add a step to my state machine to audit the process.

I guess the simplest solution would be to simply open the file (/var/www/miq/vmdb/log/audit.log) and write a message directly, though this doesn’t seem robust at all.

Any ideas?

@gmccullough can you review this question from @jockey10 and forward to another SME if necessary.

Hi @jockey10,

Writing an audit event includes writing an instance to the database as well as update the audit log entry. This is performed by the AuditEvent model which is not exposed to automate at this time.

I would suggest opening a git issue and we can look into adding it.

Thanks very much @gmccullough

I think I can get away with logging to evm.log and sending evm.log to logstash, as it looks like all of the audit messages are in there anyway.