Skip to content
This repository has been archived by the owner on Jun 4, 2021. It is now read-only.

Modifies Ubuntu 18.04 task. #436

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rngkll
Copy link

@rngkll rngkll commented Sep 17, 2019

Adds adds and modifies stages to get the ubuntu 18.04 nodes
to register.

@rngkll rngkll requested a review from a team as a code owner September 17, 2019 19:43
echo Repo: <%= repo_url %> >> /tmp/razor_complete.log
echo Node: <%= node_url %> >> /tmp/razor_complete.log

sed -i '/razor_postinstall/d' /etc/crontab
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks like the only line that has changed so far. Was the other method of stopping the postinstall script not working?

Copy link
Author

Choose a reason for hiding this comment

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

post install script was never called because ubuntu 18.04 uses systemd instead of init.

adding a line to the crontab works with systemd.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah excellent, that makes sense. Is there a reason this wouldn't work for other Ubuntu versions too? This might be a more portable way to be standard across versions.

Copy link
Author

Choose a reason for hiding this comment

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

I haven't tested this with other than ubuntu 18.04, this might work for newer version but not sure for older.

curl -s <%= store_url("ip" => "$node_ip") %>

# Send final state
curl -s <%= stage_done_url("finished") %>
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks like a duplicate of ubuntu.task/os_boot.erb. Why move it into the storing of IP?

Copy link
Author

@rngkll rngkll Sep 17, 2019

Choose a reason for hiding this comment

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

this stage is the last one, by adding this I got all the stages to run and the nodes get registered.

Copy link
Contributor

Choose a reason for hiding this comment

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

I would expect a "finished" log message to be reported to the server already, via this in os_boot.erb (which renders this file):

<%= render_template("store_ip") %>

<%= render_template("os_complete") %>

# Send final state
curl -s <%= stage_done_url("finished") %>

Is that last "finished" message not showing up?

Copy link
Author

@rngkll rngkll Sep 21, 2019

Choose a reason for hiding this comment

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

my mistake, i removed the os_boot.erb file

@smcclellan
Copy link
Contributor

Thank you for the pull request! I've added some comments to get this in shape. Overall it is more likely to be accepted if the commit description can call out specifics on what is changing, and why.

<%= render_template("os_complete") %>

# Send final state
curl -s <%= stage_done_url("os_boot") %>
Copy link
Author

Choose a reason for hiding this comment

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

the one inherited is sending the finished message not specifying the state.

is "finished" ok in this case?

Copy link
Contributor

Choose a reason for hiding this comment

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

Specifying the state, you mean stating that the task is finished?

@puppetcla
Copy link

Waiting for CLA signature by @rngkll

@rngkll - We require a Contributor License Agreement (CLA) for people who contribute to Puppet, but we have an easy click-through license with instructions, which is available at https://cla.puppet.com/

Note: if your contribution is trivial and you think it may be exempt from the CLA, please post a short reply to this comment with details. http://docs.puppet.com/community/trivial_patch_exemption.html

* Modifies stages to get the ubuntu 18.04 nodes
to register.
* Changes startup method after first boot to use cron.

fix for PR based on comments
@puppetcla
Copy link

CLA signed by all contributors.

@rngkll
Copy link
Author

rngkll commented Sep 18, 2019

@smcclellan I did some changes based on your comments, let me know if this helps.

Thanks,

@ashish1099
Copy link

any update on this one ?

@rngkll
Copy link
Author

rngkll commented Mar 15, 2021

any update on this one ?

I fairly don't remember if I signed or not, I think I did because I have no problem with signing the CLA.

I never did the test with other debian based or debian, but it should work, in some time, I'll use razor server again and will like to test them.

https://cla.puppet.com/ is not available, can someone point me to the new link.

@smcclellan
Copy link
Contributor

FYI I'm no longer involved with Razor, and not sure entirely who the POC for the product is now. @mcdonaldseanp may know perhaps?

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

Successfully merging this pull request may close these issues.

4 participants