Commit Graph

600 Commits

Author SHA1 Message Date
Frédéric Pierret
75ca54bea6
Add support for defining QubesOS repository mirror 2018-05-06 12:04:19 +02:00
Marek Marczykowski-Górecki
941d7ec448
rpm: avoid removing unrelated files on template reinstall
Fixes QubesOS/qubes-issues#3294
2018-03-21 00:47:42 +01:00
Marek Marczykowski-Górecki
e62c948068
Merge remote-tracking branch 'qubesos/pr/9'
* qubesos/pr/9:
  Use full path for tools normally in /sbin
2018-03-20 00:58:54 +01:00
Marek Marczykowski-Górecki
c7bbdbf51c Use full path for tools normally in /sbin
Do not rely on Fedora-specific setting - having /sbin in PATH also for
normal user. This allows to build templates on Debian.
2018-03-10 02:03:59 +01:00
Marek Marczykowski-Górecki
310837b4ee Add configurable template root volume size
Allow to override default 10G.
2018-03-10 02:02:21 +01:00
Frédéric Pierret
4d73c0abc7
Add CENTOS & EPEL mirror definition 2017-11-23 10:08:43 +01:00
Frédéric Pierret
5da4426ac3
Rename REPO_BASEURL_PREFIX to FEDORA_MIRROR for consistency with builder-debian 2017-11-05 10:43:25 -05:00
Frédéric Pierret
0ec5146368
TEMPLATE_ENV_WHITELIST: add REPO_BASEURL_PREFIX 2017-11-02 09:04:09 -04:00
Frédéric Pierret
aeed2f1fc8
Add support for templates upload and syncing 2017-10-29 14:31:02 -04:00
Marek Marczykowski-Górecki
9a6b16dc6f
version 4.0.0 2017-10-19 16:45:24 +02:00
Marek Marczykowski-Górecki
2d4975c091
Change partition layout
Put root filesystem as the last partition, to ease resizing.

Fixes QubesOS/qubes-issues#3173
2017-10-17 23:59:00 +02:00
Marek Marczykowski-Górecki
fcc771715a
Remove more intermetiate files when DISCARD_PREPARED_IMAGE=1 2017-09-26 18:52:38 +02:00
Marek Marczykowski-Górecki
fe05ad6935
Use more generic variable for not keeping prepared image
Use this:
DISCARD_PREPARED_IMAGE=1
2017-09-26 02:48:35 +02:00
Marek Marczykowski-Górecki
bca3759c78
travis: do not keep prepared_image/*.img, to save space
There is limited disk space available on Travis-CI. Build product it
thrown away anyawy, so do not keep intermediate files (normally useful
to speedup next build).
2017-09-26 01:51:10 +02:00
Marek Marczykowski-Górecki
1d407d1fc5
Merge remote-tracking branch 'qubesos/pr/2'
* qubesos/pr/2:
  Fix parameter expansion for appmenus directory
  Whitelist APPMENUS_DIR setting
  Update in 'help' target for 'make clean' description
2017-09-07 13:49:11 +02:00
Frederic Pierret (Epitre)
9a1032e2eb
Fix parameter expansion for appmenus directory 2017-09-06 18:59:42 +02:00
Marek Marczykowski-Górecki
7c053165f3
Whitelist APPMENUS_DIR setting 2017-09-06 18:58:43 +02:00
Marek Marczykowski-Górecki
c5d316b1ff
Whitelist APPMENUS_DIR setting 2017-09-04 01:24:31 +02:00
fepitre
d1564aa351 Update in 'help' target for 'make clean' description 2017-08-25 16:00:45 +02:00
Marek Marczykowski-Górecki
061eb5dc02
Add TEMPLATE_OPTIONS to whitelisted environment variables
QubesOS/qubes-issues#2954
2017-08-10 12:23:15 +02:00
Marek Marczykowski-Górecki
5de7c6deed
template: add SRC_DIR to environment vars whitelist
It is needed to calculate path to individual components.
2017-07-29 11:19:08 +02:00
Marek Marczykowski-Górecki
be395a8ada
Do not use full path to mountpoint program
It may reside in different places (/bin in Debian, /usr/bin in Fedora).
Use $PATH for this.
2017-07-11 23:56:30 +02:00
Marek Marczykowski-Górecki
78a2699371
rpm: drop dependencies on dom0 stuff
Installing template should _not_ be a way to install all the Qubes dom0.
On the other hand, those dependencies prevent template installation from
a VM - through Admin API in Qubes 4.0
2017-06-25 15:23:32 +02:00
Marek Marczykowski-Górecki
11d1b89bc5
version 3.1.0 2017-06-24 14:56:26 +02:00
Marek Marczykowski-Górecki
9b2078d346
Add support for template with partition table on root.img
When TEMPLATE_ROOT_WITH_PARTITIONS is set, include (GPT) partition table
and install actual OS on the first one. This allows installing grub, or
other bootloader.

Fixes QubesOS/qubes-issues#2577
2017-06-24 01:28:37 +02:00
Marek Marczykowski-Górecki
a97fe13c1b
Filter environment exposed to template build scripts
Do not expose host envionment there. This, among other things, fixes some
packages that create/modify /home/user ($HOME) in post-installation
script...
2017-06-24 01:28:36 +02:00
Marek Marczykowski-Górecki
bb836e5d46
Call qvm-template-postprocess if present instead of internal script
Actions required after template installation differs between Qubes
releases. Lets keep template builder universal and just call appropriate
command provided by version-specific component (probably
qubes-core-dom0 package), if present. Otherwise use old script (for
Qubes before 4.0).

Add --really parameter to prevent misuse. This tool may override
template data without further confirmation.

QubesOS/qubes-issues#2412
2016-11-02 06:14:34 +01:00
Marek Marczykowski-Górecki
819757e754
version 3.0.6 2016-05-18 02:58:22 +02:00
Marek Marczykowski-Górecki
d976ffd3a6
Make template builder working on Debian
1. Use bash explicitly where required
2. Don't use bash-isms where not.

QubesOS/qubes-issues#1907
2016-04-20 10:23:36 +02:00
Marek Marczykowski-Górecki
b427341d28
Rename function chroot to chroot_cmd
Do not create function with the same name as standard command, it is
very confusing.

Fixes QubesOS/qubes-issues#1174
2016-04-20 01:59:34 +02:00
M. Vefa Bicakci
f51e3a09fe
Fix a minor losetup usage bug 2016-04-10 00:00:00 -04:00
Marek Marczykowski-Górecki
a5f018da1a
version 3.0.5 2016-02-11 04:13:33 +01:00
Marek Marczykowski-Górecki
f7a3ce03e3 Tag for commit 09af4b9433
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJWe8BwAAoJEBu5sftaTG2tewIP/jT8RemihLiFmDmJpqkuIU6Q
 OuGaX8nODr+ay+LD0QCb/PCpVty+hUO3SMladaNpwEpWwAlcC1rt1MGdLJQAD2Aq
 tsZ3EeBmm3UnxWHQ8/qe6GzzyqFcIHwwrutvjDputBKd6Qjq5Bc96AvRBfgSJe52
 twP/xvdMj9Wjnd3R0+ndrve08TEo5fZI578eCcNHHTD9GT50CRBEcMGeB20rbJ2V
 l2viWPO2VXAGkrzkhOTi/L2YiyioG79kK64ZNnpemL7t+E5VQJ81l7W9GC17RVIu
 gLElf1nINI6LKbmtfL5xnrN2DwDH+pZVjYj4Isnxh6KyI8Eo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JzQ4pt3+wPVRqhPH+emjJa
 iOtHTI44Ddj9kQnkn+n9PVz0ivqLWukb1PyssaTbjqAdQ9DtLX0iQKaBoPAn0mjG
 Ffp7NmFaj1FJlZcn2wZg
 =VdWX
 -----END PGP SIGNATURE-----

Merge tag 'jm_09af4b94'

Tag for commit 09af4b9433

# gpg: Signature made Thu 24 Dec 2015 10:52:48 AM CET using RSA key ID 5A4C6DAD
# gpg: Good signature from "Jason Mehring (Qubes OS Signing Key) <nrgaway@gmail.com>"
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: E0E3 2283 FDCA C1A5 1007  8F27 1BB9 B1FB 5A4C 6DAD

* tag 'jm_09af4b94':
  functions.sh: Allow generic TEMPLATE_FLAVOR_DIR that matches all flavors, or even no flavors
  functions.sh: unset "build_step_files" var to prevent loading same files if no files found on another run
  function.sh:  Allow multiple template directories to be searched
2015-12-25 19:06:41 +01:00
Jason Mehring
09af4b9433 functions.sh: Allow generic TEMPLATE_FLAVOR_DIR that matches all flavors, or even no flavors
Use an asterisk in place of a '+flavor' to indicate a template directory to be applied
to all flavors, or no flavor at all.

    *:/home/user/qubes/qubes-src/some-repo/template-directory
2015-12-24 04:46:50 -05:00
Jason Mehring
b4fbcb8071 functions.sh: unset "build_step_files" var to prevent loading same files if no files found on another run 2015-12-23 05:16:24 -05:00
Jason Mehring
b61fdaf843 function.sh: Allow multiple template directories to be searched
Return all and run matches instead of only one which allows flavors
like salt to have multiple optional modules like mgmt-salt-dev to
run installation scripts in template subdirectories.
2015-12-15 22:25:43 -05:00
Marek Marczykowski-Górecki
621a21a528
version 3.0.4 2015-11-29 03:57:19 +01:00
Marek Marczykowski-Górecki
ff22e7d199
rpm: remove icons on package uninstallation 2015-11-26 06:27:47 +01:00
Patrick Schleizer
bdd06c77af create_template_list.sh enhancements
- allow to pass environment variable '$YUM_OPTS' (to allow adding for example '--assumeyes')
- only try to uninstall existing template package if already installed to avoid failing and unnecessary output and prompts
- output
- refactoring
2015-10-12 09:41:35 +00:00
Marek Marczykowski-Górecki
24f3f78e72
Merge remote-tracking branch 'origin/pr/10'
* origin/pr/10:
  - Fixed 'Qubes Builder: install-templates.sh wants to install the 'same' image multiple times'.

Fixes QubesOS/qubes-issues#1109
2015-10-06 15:45:12 +02:00
Patrick Schleizer
aba808291e - Fixed 'Qubes Builder: install-templates.sh wants to install the 'same' image multiple times'.
- By default, add only newest versions to the list of files to be installed.
- Add older versions commented out by default.
- Do not try to install out commented versions.
- Renamed variable file to file_name ['file' is a unix standard utility].
- Enabled errexit.
- Refactoring, keep write variables part simpler by just writing, not determining variables contents.
- use more quotes

Fixes https://github.com/QubesOS/qubes-issues/issues/1109.
2015-09-20 17:38:11 +02:00
Patrick Schleizer
ec69d65372
enable errtrace right after xtrace 2015-08-10 22:59:53 +02:00
Patrick Schleizer
d16fac0b56
verbosity fixes 2015-08-10 22:58:07 +02:00
Marek Marczykowski-Górecki
0b8d27c1fb
Add missing 'set +x', move debug message to be visible
Since 'true' is used to show traced messages, it needs to be placed
after 'set -x'.
2015-08-05 01:41:35 +02:00
Marek Marczykowski-Górecki
5897b1a882
Merge remote-tracking branch 'origin/pr/8'
* origin/pr/8:
  fixed 'verbosity disabling bug' https://github.com/QubesOS/qubes-issues/issues/1100 Deprecated functions setVerboseMode, getXtrace, setXtrace and variable XTRACE, because those were broken and their only use case was function umount_kill. Re-implemented disabling xtrace in function umount_kill, if variable VERBOSE is lower than or equal 2.
2015-08-05 01:40:28 +02:00
Marek Marczykowski-Górecki
645a903995 Tag for commit 3640af684f
-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJVwDzeAAoJEBu5sftaTG2tL2oQAJd/9roUz5IMyr7maGNgVwUC
 sNrExi5SNr5J2aYjuVmXCj6pYQiFnDeFHkcdtO4x8DPjEil7m63wVFX7AG+W/2yv
 KtI0+lBW+uy0cUudbrYCdVGCfMg5/1W9Vh6ZiDCh5Rw+b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PSOAVItPNDiDaeTB2
 31G1Wf9ndOHC4QPb71CEOq4iSP/c1FYRjFFuKLWvsX1XlcVoIbsXdaRKJDDdkjxb
 ru58uCvYo+wNKZX9VzR6g6bVzObnGdl2j6ea8v/fSjaSAvry+1Ob1ZC9+Qt+DyZJ
 Rcj6VvAA/645qJxjQ3nC/siADboN+hQbDzSL12hVjHbfXDHrFsBQQZH0Em26sqcw
 RR85sMwmvPP2nccD3AhLbq800J0zMUhWqh1vcuz1+aOD//vn64KjONSeczuyQObG
 tbkGIp1hU6FiYWWmL2K3
 =cRXq
 -----END PGP SIGNATURE-----

Merge tag 'jm_3640af68'

Tag for commit 3640af684f

# gpg: Signature made Tue 04 Aug 2015 06:17:34 AM CEST using RSA key ID 5A4C6DAD
# gpg: Good signature from "Jason Mehring (Qubes OS Signing Key) <nrgaway@gmail.com>"
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: E0E3 2283 FDCA C1A5 1007  8F27 1BB9 B1FB 5A4C 6DAD

* tag 'jm_3640af68':
  functions.sh: fix GLOBAL_CACHE error whay array does not yet exist
2015-08-05 01:16:48 +02:00
Patrick Schleizer
e84645e597
fixed 'verbosity disabling bug'
https://github.com/QubesOS/qubes-issues/issues/1100
Deprecated functions setVerboseMode, getXtrace, setXtrace and variable XTRACE, because those were broken and their only use case was function umount_kill. Re-implemented disabling xtrace in function umount_kill, if variable VERBOSE is lower than or equal 2.
2015-08-04 17:59:50 +02:00
Jason Mehring
3640af684f functions.sh: fix GLOBAL_CACHE error whay array does not yet exist 2015-08-04 00:17:09 -04:00
Patrick Schleizer
2167225d01 minor indent 2015-08-04 04:51:47 +02:00
Marek Marczykowski-Górecki
48c942c4a6
Propagate error code from rpmbuid
Fixes qubesos/qubes-issues#1099
2015-08-04 04:00:43 +02:00