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

update: set -d and -f for release updates and thick jail updates #810

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

tschettervictor
Copy link
Collaborator

@tschettervictor tschettervictor commented Jan 14, 2025

#668
@michael-o This should fix updating a thick jail and also a base release. I have added both "-d" and "-f" to make sure "update_release" and "update_jail" know where they are supposed to set the workdir, basedir, and conf file.

Can you test?

Simply do a bastille update RELEASE or bastille update jail

@michael-o
Copy link
Contributor

michael-o commented Jan 14, 2025

Will happily test this week.

@tschettervictor tschettervictor changed the title update: set -d and -f for release updates and think jail updates update: set -d and -f for release updates and thick jail updates Jan 14, 2025
@bmac2
Copy link
Collaborator

bmac2 commented Jan 16, 2025

@michael-o let me know when you have tested this. I will test it in the morning myself.

@yaazkal @tschettervictor

@michael-o
Copy link
Contributor

@michael-o let me know when you have tested this. I will test it in the morning myself.

@yaazkal @tschettervictor

On my radar for this week.

usr/local/share/bastille/update.sh Outdated Show resolved Hide resolved
usr/local/share/bastille/update.sh Outdated Show resolved Hide resolved
usr/local/share/bastille/update.sh Outdated Show resolved Hide resolved
@michael-o
Copy link
Contributor

You might also consider to sync var names with upgrade PR.

usr/local/share/bastille/update.sh Outdated Show resolved Hide resolved
env PAGER="/bin/cat" freebsd-update ${OPTION} \
--not-running-from-cron \
-b "${_releasepath}" \
-d "${_releasepath}/var/db/freebsd-update" \
Copy link
Contributor

Choose a reason for hiding this comment

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

Do you really the update database be part of the release? It is not a jail after all?!

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It's the working directory. I figured best to keep it all consigned to the jail.

Not?

Copy link
Contributor

Choose a reason for hiding this comment

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

Well, it is not a jail, is it? You are updating a release which is used for bootstrapping and thin jails. Update management should be out of band. I'd like to know what others think here. @bmac2 @jdhg-orbiware

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Oh sorry, that is the release we are talking about here. I thought it was the jail.

Still, we are updating the release, and I'm not sure if the database is touched in there or not.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@michael-o I closed our other 2 conversations here about the -b option. We can discuss here.

Because this is a release, we do need the -b option. Unlike jails, where you can specify the -j option, we need to tell freebsd to use the release as a base directory, and also where the workdir should be.

Don't you think?

usr/local/share/bastille/update.sh Outdated Show resolved Hide resolved
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

Successfully merging this pull request may close these issues.

3 participants