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

"error_0377" in words.xml refers to "host", operative function in striker-initialize-host tests $anvil->data->{data}{type} ne "node") #671

Open
maholloway opened this issue Jun 3, 2024 · 1 comment
Assignees
Labels
bug low low priority
Milestone

Comments

@maholloway
Copy link

This issue pertains to the following package versions:
anvil-core-2.92-1.2.9cfa.el9.noarch
anvil-striker-2.92-1.2.9cfa.el9.noarch

Using striker-initialize-host with --type host results in the following error:

[root@mh-striker01 ~]# striker-initialize-host --target 192.168.1.175 --password $ANVIL_PASS --type host
[ Error ] - The '--type' must be 'host' or 'dr'. Was given: [host].

This appears to be due to the if statement on line 1129 of striker-initialize-host, which reads [in context]:

...
1129         if (($anvil->data->{data}{type} ne "node") && ($anvil->data->{data}{type} ne "dr"))
1130         {
1131                 $anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 0, 'print' => 1, key => "error_0377", variables => { type => $anvil->data->{data}{type} }});
1132                 update_progress($anvil, 100, "error_0377,!!type!".$anvil->data->{data}{type}."!!");
1133                 $anvil->nice_exit({exit_code => 1});
1134         }
...

Apparent fix: Change error_0377 to refer to "node" rather than "host" or modify line 1129 of striker-initialize-host to test for --type host instead of --type node

@maholloway
Copy link
Author

Works a treat with the "node" value for the --type flag. Output:

[root@mh-striker01 ~]# striker-initialize-host --target 192.168.1.175 --password $ANVIL_PASS --type node
'Initialize host' job: [] picked up.
Use of uninitialized value in concatenation (.) or string at /usr/sbin/striker-initialize-host line 1163.
Connecting to the target: [[email protected]]...
Connected!
Adding repositories.
Updating the target's operating system prior to package install.
[ Note ] - This step can take a while to finish, and there will be no input here until it completes.
Removing conflicting packages.
Will now install: [anvil-node].
Verifying installation.
Success!
Successfully added/confirmed the filter in lvm.conf.
Finished! The target should be ready for initial configuration shortly. If it isn't, please check that the 'anvil-daemon' daemon is running.
[root@mh-striker01 ~]#

@fabbione fabbione added this to the Parking lot milestone Aug 28, 2024
@digimer digimer self-assigned this Aug 28, 2024
@digimer digimer added bug low low priority labels Aug 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug low low priority
Projects
None yet
Development

No branches or pull requests

3 participants