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

kola/tests/ignition: add test for checking journald logs #1329

Merged
merged 1 commit into from
May 11, 2020

Conversation

sohankunkerkar
Copy link
Member

@sohankunkerkar sohankunkerkar commented Apr 8, 2020

This test will validate the changes in coreos/ignition#958 to see if we're successfully sending the journald log entry for a user-provided config.

@sohankunkerkar sohankunkerkar force-pushed the ign-kola-test branch 2 times, most recently from f8eac5c to 303d493 Compare April 28, 2020 21:36
@sohankunkerkar
Copy link
Member Author

Waiting for a new release of ignition to test this change.

@sohankunkerkar sohankunkerkar force-pushed the ign-kola-test branch 2 times, most recently from 6302f96 to 946202b Compare May 7, 2020 16:11
@sohankunkerkar sohankunkerkar changed the title WIP kola/tests/ignition: add test for checking journald logs kola/tests/ignition: add test for checking journald logs May 8, 2020
Copy link
Member

@ashcrow ashcrow left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's looking pretty good so far. A few notes added.

Copy link
Member

@zonggen zonggen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ran the test locally and ran without issue as the code looks good to me.

@sohankunkerkar sohankunkerkar force-pushed the ign-kola-test branch 5 times, most recently from 20ae9cd to 15b6bd6 Compare May 8, 2020 21:36

func sendJournaldLog(c cluster.TestCluster) {
m := c.Machines()[0]
// See https://github.com/coreos/ignition/pull/958
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect 👍

// for the MESSAGE_ID source. It will track the
// journal messages related to an ignition config
// provided by the user.
out := c.MustSSH(m, fmt.Sprintf("journalctl -o json-pretty MESSAGE_ID=%s | jq -s '.[] | select(.IGNITION_CONFIG_TYPE == \"user\")' | wc -l", ignitionJournalMsgId))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is much clearer.

@cgwalters
Copy link
Member

/lgtm

@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ashcrow, cgwalters, sohankunkerkar

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit 4e2ffda into coreos:master May 11, 2020
@sohankunkerkar sohankunkerkar deleted the ign-kola-test branch May 11, 2020 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants