Commit Graph

888 Commits

Author SHA1 Message Date
Matthias Clasen
f5113085e1 ostree: Remove duplicate command in help output
The 'remote' command was listed twice. Also, the list
was almost-but-not-quite alphabetically sorted. Fix
that too.
2012-08-23 20:03:40 -04:00
Colin Walters
419965e6e3 build: Make /etc/kernel scripts default to automatic
When not cross compiling, we can test for /etc/kernel.  This fixes the
build automatically on RHEL6 for example.
2012-08-23 15:19:41 -04:00
Colin Walters
344a7b3fd3 packages: Add files that should have been in previous commit
These were intended to be with the embedded-dependencies commit.
2012-08-23 08:52:23 -04:00
Colin Walters
79f993beb4 pull: Only fetch pack files if we want more than 66% of their objects
This avoids some pathologically bad cases where we would fetch a 25MiB
pack file only to extract one 5KiB object from it.
2012-08-22 19:45:01 -04:00
Colin Walters
b36b19eaf8 pull: Exit mainloop immediately if we encounter an error
Otherwise we'll just hang.
2012-08-22 19:45:00 -04:00
Colin Walters
f115a8943a pack: Support --content-only
This should be useful for implementing more sophisticated packing
strategies.

Also clean up the pack size default handling.
2012-08-22 19:45:00 -04:00
Colin Walters
ece71b22c5 pull: Set an error when we get an unsuccessful HTTP response
Otherwise we'll e.g. try to parse 404 HTML as an object which will
fail.
2012-08-22 19:45:00 -04:00
Giovanni Campagna
a97bcc68d7 Add infrastructure for automatic kernel updates
If the distribution supports running arbitrary scripts at kernel
updates, we can hook into it and update the ostree side of things
automatically.
2012-08-20 23:01:58 +02:00
Giovanni Campagna
affa5755a6 ostadmin: add update-kernel command to regenerate initramfs and boot config
This command regenerates kernel-dependent files. It is meant to
be run after kernel upgrades in the host distribution, to keep
the ostree installation running, and attempts to figure out the
right version automatically (and without changing the ostree checkout)
2012-08-20 23:01:57 +02:00
Giovanni Campagna
1057f8289c Don't fail for EPERM when hardlinking
As the manual page doesn't say, but the in-code kernel documentation
shows, hardlinking for normal users can fail for a variety of
reasons (including very common situations such as non regular file
or non writable file), if the owner of the file does not match
the user linking (e.g. when checking out a shadow repo with a root-
owned master).
If that happens, fail back silently to copying instead of aborting
the whole operation.

https://bugzilla.gnome.org/show_bug.cgi?id=682298
2012-08-20 23:01:57 +02:00
Giovanni Campagna
1d93a743dc ostree-run-triggers: fix typo in filename comparison function
The comparison function was comparing the first file to itself,
and this resulted in triggers being run in random order.

https://bugzilla.gnome.org/show_bug.cgi?id=682297
2012-08-20 23:01:57 +02:00
Colin Walters
a571c83d82 embedded-dependencies: Fix ACLOCAL_FLAGS, update for libgsystem
* Handle the libgsystem submodule
* ACLOCAL_FLAGS was broken
* Add srpm-embedded
2012-08-19 15:05:01 -04:00
Stef Walter
f5cf21e471 Include pull and other external commands in usage output 2012-08-19 15:05:01 -04:00
Giovanni Campagna
edf69d6283 ostadmin: fix command line handling in the builtins
Common code was duplicating the command name and not shifting
arguments properly, which thus required the builtins to be aware
of it, instead of being treated like subcommands.
2012-08-18 19:21:22 +02:00
Colin Walters
22aa38a7da configure: Fix libsoup detection
* The configure arg was named incorrectly; we don't rely on
libsoup-gnome, just libsoup.
* We need to use AS_IF
2012-08-14 13:11:45 -04:00
Colin Walters
05bf1fed99 autogen: Fetch submodules before running automake
Otherwise automake can't find src/libgsystem.
2012-08-14 12:52:46 -04:00
Stef Walter
66c8a1d3f6 Support non-builtin commands
* Support executing commands in the path
 * This makes 'ostree-pull' work as 'ostree pull'
2012-08-10 15:55:26 +02:00
Colin Walters
179fc65947 triggers: Print execution time for each trigger 2012-08-05 16:39:57 -04:00
Colin Walters
36b6ad41cb ostadmin: Use g_spawn_check_exit_status()
Just code cleanup.
2012-08-05 16:39:57 -04:00
Colin Walters
a6c19aa00c ostadmin: Change command line for qemu deploy helper
The qemu helper really wants to copy kernel modules, but not
update the system bootloader.  Allow it to reuse ostadmin for
this.

Note that our previous path of shelling out to "cp -al" broke because
it refused to make cross-device links.

# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
# On branch master
# Your branch is ahead of 'origin/master' by 1 commit.
#
# Changes to be committed:
#   (use "git reset HEAD <file>..." to unstage)
#
#	modified:   src/libotutil/ot-gio-utils.c
#	modified:   src/libotutil/ot-gio-utils.h
#	modified:   src/ostadmin/ot-admin-builtin-deploy.c
#
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#	embedded-dependencies/glib/
#	embedded-dependencies/libsoup/
2012-08-05 16:39:57 -04:00
Colin Walters
09707780b9 ostadmin: Add --ostree-dir directory
This will be used by the qemu deployment script.
2012-08-05 16:39:57 -04:00
Stef Walter
31d129fab4 Automatically populate the git submodules in autogen.sh 2012-07-31 15:26:42 +02:00
Colin Walters
1804d944d2 TODO: update 2012-07-31 00:15:02 -04:00
Colin Walters
5284d21f8d ostadmin: Print an error message if run as non-root
See https://bugzilla.gnome.org/show_bug.cgi?id=680823
2012-07-30 10:29:45 -04:00
Colin Walters
a179138a23 ostadmin: [incompat syntax change] Allow deploying any revision
The old command line syntax assumed you wanted the latest from
a given revision, but to bisect, you really want the ability
to deploy any given one.

Old:
$ ostadmin deploy gnomeos-3.6-i686-{runtime,devel}

New:

$ ostadmin deploy trees/gnomeos-3.6-i686-runtime
$ ostadmin deploy trees/gnomeos-3.6-i686-devel

And note that the deploy directory now changes to:
/ostree/trees/gnomeos-3.6-i686-devel

And now it's possible to:

$ ostadmin deploy trees/gnomeos-3.6-i686-devel trees/gnomeos-3.6-i686-devel^^^
2012-07-26 10:56:32 -04:00
Colin Walters
5bbdce2c06 pull: When --depth is specified, ensure we have all requested objects
We were previously optimizing by skipping object traversal if the refs
were unchanged, but if the user specifies a deeper depth than they did
before.
2012-07-26 10:17:41 -04:00
Colin Walters
a310eb861b core: Add context when we fail to chmod()/chown()
This helps make things less confusing when we try to create a file not
owned by our uid, such as running ostree-pull as non-root on a
repository owned by root.
2012-07-19 11:01:39 -04:00
Colin Walters
0d86702115 core: Drop ot_clear_hashtable for g_clear_pointer() 2012-07-17 08:18:43 -04:00
Colin Walters
43a2fec6a8 core: Drop ot_clear_ptrarray in favor of g_clear_pointer 2012-07-17 08:16:54 -04:00
Colin Walters
2ced4abf11 core: Drop ot_clear_gvariant() in favor of g_clear_pointer 2012-07-17 08:14:33 -04:00
Colin Walters
57fcafd1ab core: Remove ot_clear_checksum() in favor of g_clear_pointer() 2012-07-17 08:08:57 -04:00
Colin Walters
c8d7fc216d core: Use g_spawn_check_exit_status() 2012-07-17 08:06:20 -04:00
Colin Walters
6b31c580ca pull: Only take up one terminal line for status output
And print total bytes transferred at the end.
2012-07-16 22:35:18 -04:00
Colin Walters
b2c2bf7e04 Fix libgsystem submodule 2012-07-15 18:29:15 -04:00
Colin Walters
da43fb6db5 Hard require GLib 2.34
Anyone wanting to build against an earlier version can use the
embedded-dependencies system.
2012-07-15 18:22:41 -04:00
Colin Walters
464f4a81c9 Add libgsystem as git external
Don't replace ot_lfree and stuff yet though...to much code churn.
2012-07-15 11:59:05 -04:00
Colin Walters
95921bcbf0 pull: Correctly display concurrent libsoup requests
The "status text" code was assuming that libsoup was only doing one
thing at a time, but that's never been the case.  Change the code to
display the status of all active requests.
2012-07-12 11:19:15 -04:00
Colin Walters
664e9b404d core: drop dead/unused code
The daemon is a nice idea but needs a lot more thought.  Let's just
delete the unused code for now and come back to it later.
2012-06-30 13:49:25 -04:00
Colin Walters
311493338e core: Drop ot_gfile_new_for_path
Not necessary anymore since we switched to GIO_USE_VFS=local in the
binaries.
2012-06-30 13:42:24 -04:00
Colin Walters
d5a1f1deda pull: Fix a memory leak 2012-06-28 15:18:10 -04:00
Colin Walters
a98ca05676 pull: Fix use-after-free in async fetcher
Refcount the pending data structure.
2012-06-28 15:06:18 -04:00
Colin Walters
31b439b84c Release 2012.8 2012-06-27 22:38:12 -04:00
Colin Walters
6bfbb8b239 build: Use LDADD libraries to link with, not LDFLAGS
This should fix the build with embedded glib.
2012-06-27 22:38:12 -04:00
Colin Walters
667c3bcb10 Make more compiler warnings into errors
In particular, I want -Werror=format=2 to catch format string bugs.
2012-06-27 22:26:16 -04:00
Colin Walters
d596615bab main: Fix a format string error 2012-06-27 22:26:16 -04:00
Colin Walters
671303d1ab embedded deps: Properly quote/handle PATH/LDFLAGS 2012-06-27 20:16:36 -04:00
Colin Walters
a7b917c856 core: Check out asynchronously
This can be a large performance win in certain circumstances:

 * Cold buffer cache (we don't block the whole process)
 * Requiring a copy instead of hardlink
2012-06-21 18:05:13 -04:00
Colin Walters
eba0ff75cc tests: Just use OT_TESTS_DEBUG to say "save test data" 2012-06-21 11:42:45 -04:00
Colin Walters
7cce6e5ba1 pull: Properly propagate errors 2012-06-20 15:42:41 -04:00
Colin Walters
0cb4fe66f8 build: Fix syntax error in non-embedded build case 2012-06-20 15:42:19 -04:00