Commit Graph

1717 Commits

Author SHA1 Message Date
Ryan Harper df2c3c6aca Update grub2 configuration for UEFI
Update grub2 configuration for UEFI booting with fallback to bios mode.
Include new detection scheme so we don't list existing partitions of the
installer.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-22 13:21:14 -05:00
Ryan Harper 522a546b5c Modify geninstaller for uefi booting
Switch image to use overlay partition and use uefi layout and boot loader
configuration.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-22 13:15:00 -05:00
Ryan Harper a744245f03 Add install_deps_$(ARCH) target to split out per-arch deps
Move arch specific packages into their own target

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-22 08:44:18 -05:00
raharper 88334d4075 Merge pull request #43 from CanonicalLtd/render_network_config
Render network config
2015-09-21 16:43:47 -05:00
Ryan Harper 3f88e6ea09 Merge branch 'render_network_config' of github.com:CanonicalLtd/subiquity into local-render-network
Conflicts:
	subiquity/controllers/filesystem.py
2015-09-21 16:42:18 -05:00
Ryan Harper 6bbf6ba1c8 Fix up user configuration in install image
We use cloud-init to create the initial user on the target system.
Ensure the password login works, that it has a shell (/bin/bash)
and sudo privs via group admin.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 16:40:36 -05:00
Ryan Harper acab44c1ec Update dhclient apparmor profile under overlayroot
With updated kernels, overlayroot programs will fail with
a disconnected_path error.  Resolve our use of dhclient by
adding the allow_disconnected flag to the profile.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 16:40:35 -05:00
Ryan Harper 9138137057 Fix up async install commands
- Pass in write_fd into async commands so output calls refresh
- Hack the threadpool to a single task so we trivially block on the long
  install and don't invoke our post install until the other is complete
- lots of debugging for command outputs.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 16:40:35 -05:00
Ryan Harper 3f2a64b032 Fix curtin invocation
Move config writeout to a non-coroutine method.
Add realname collection (needed for userinfo)
Add debugging to help find issue with async commands

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 16:40:35 -05:00
Ryan Harper fbee724441 Split out curtin configuration files
Break out curtin configuration data into multiple configuration files
This sets up our initial install (network +storage) and our secondary
run (postinstall user config).

- encrypt the users password and never log the original value

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>

Conflicts:
	subiquity/controllers/filesystem.py
2015-09-21 16:40:26 -05:00
Ryan Harper 53b9e59929 Generate network configuration
Update network model to generate a network configuration for each
active network device.  Note, some of the examples won't quite work
since we now want updated probert data which includes new information
about the source of any discovered ip.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 16:39:54 -05:00
Ryan Harper 0beb904448 Fix up user configuration in install image
We use cloud-init to create the initial user on the target system.
Ensure the password login works, that it has a shell (/bin/bash)
and sudo privs via group admin.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 13:17:24 -05:00
Ryan Harper e888b13707 Update dhclient apparmor profile under overlayroot
With updated kernels, overlayroot programs will fail with
a disconnected_path error.  Resolve our use of dhclient by
adding the allow_disconnected flag to the profile.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-21 13:16:06 -05:00
Adam Stokes 1d1f9d5d8f Add network set default route view
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-16 10:06:50 -04:00
Adam Stokes 1ebeb45240 Merge pull request #42 from CanonicalLtd/fix-serial-mode
Fix serial mode
2015-09-15 07:51:19 -04:00
Ryan Harper 2cf528d6d3 Fix serial mode
We can't use curses_display with an external event loop (tornado).  The good
news is that we don't have to.  Instead we switch to using agetty to bypass
login, specify the installer and options to execture.  This also handles
respawning the installer and works both on serial and without.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-14 16:40:28 -05:00
Adam Stokes 9d39025f2e disable ceph/iscsi views for now
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-14 14:44:15 -04:00
Ryan Harper 27fb85d9b7 Fix up async install commands
- Pass in write_fd into async commands so output calls refresh
- Hack the threadpool to a single task so we trivially block on the long
  install and don't invoke our post install until the other is complete
- lots of debugging for command outputs.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-11 15:53:34 -05:00
Adam Stokes dbad01aa11 Add additional filesystem sections
This contains views/controllers/models for setting RAID,
assigning Ceph storage, and iSCSI.

They are all in their initial implementation stage and
does require more work on the backend to make these
items usable.

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-11 15:16:39 -04:00
Ryan Harper 27309f52bd Fix curtin invocation
Move config writeout to a non-coroutine method.
Add realname collection (needed for userinfo)
Add debugging to help find issue with async commands

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-11 13:12:26 -05:00
Ryan Harper 30707efc56 Split out curtin configuration files
Break out curtin configuration data into multiple configuration files
This sets up our initial install (network +storage) and our secondary
run (postinstall user config).

- encrypt the users password and never log the original value

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-11 10:30:46 -05:00
Ryan Harper baf6e377a9 Generate network configuration
Update network model to generate a network configuration for each
active network device.  Note, some of the examples won't quite work
since we now want updated probert data which includes new information
about the source of any discovered ip.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-11 10:30:46 -05:00
Adam Stokes b3f09832d4 Merge pull request #39 from CanonicalLtd/fix-network-display
Fix network connection display
2015-09-08 16:03:36 -04:00
Ryan Harper a1abcb31ac Fix network connection display
- Adjust the size of the column with iface name, cap the max size
- Find and remove any set of 'Unknown' displays of info
- Replace the 'Checking' status with the current state of the connection
  For now, it will always be definitive since we check for connections
  upon boot.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-08 14:49:24 -05:00
Adam Stokes 0b5dd20f63 Additional disk models added
initial models for Ceph, iSCSI, RAID

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-08 11:13:16 -04:00
Adam Stokes 2f738c7ad8 Merge pull request #38 from CanonicalLtd/fix-no-nics
Fix no nics
2015-09-03 14:50:23 -04:00
Ryan Harper 8aedabef3b Add nonic example file
Test nonics with:  MACHINE=examples/nonics.json make

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 13:47:35 -05:00
Ryan Harper dfc9d02b02 Handle when we don't have any nics at all.
Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 13:46:51 -05:00
Ryan Harper 7c06be6d82 lint fixes for recent code
Fix up make lint for files we've touched.  Still some work to do for others

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 13:35:07 -05:00
Ryan Harper fb5e7b7e91 Fix 10 Gig network display
python3 likes to make floating point numbers when dividing a lot.
Fix with cast to int.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 12:53:08 -05:00
Ryan Harper 0fca368ba4 Update probert commit revno
Update probert revno to use newer network probing data.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 12:50:35 -05:00
Ryan Harper bcf4f37ea4 Fix typo in fetching ip source and provider
Copy and paste error on fetching ip source provider.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 12:49:21 -05:00
Ryan Harper d8814c6648 Update networking model and view to use new probert data
Probert now collects more information on ips, bonds and bridges
Use this information to display Network view closer to spec.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-03 12:47:17 -05:00
Adam Stokes 2ff52fdaec Add disk info view
Adds ability to view disk information via hdparm
if run as root, otherwise, will print error to
the ui (ie. permission denied.)

As a result updated the run_command routine
to be a little more robust.

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-02 15:21:14 -04:00
Adam Stokes 11e76e85d2 add probert to ignore list
Gets pulled in externally, lets not commit it
twice by accident

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-09-02 14:08:39 -04:00
raharper 0991ac41cd Merge pull request #37 from CanonicalLtd/fix-max-partsize
Fix max partsize
2015-09-01 17:06:45 -05:00
Ryan Harper fbb8eb09fb Adjust partition alignment for GPT and curtin sgdisk
Curtin uses sgdisk to create partitions.  To avoid sgdisk
fixing alignment issues we ensure that all partitions are
1M aligned.

GPT partitions also require space at the end, reserve the
same number of sectors (1K, 2048 512b sectors) at the
start and end of the disk.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-01 17:01:07 -05:00
Ryan Harper 7ff3f549c2 Fix partition size selection and logging
- Fix max size partition edge case
- Ensure if nothing is entered we select the max size
- Adjust offset and size calculations for actions

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-01 11:28:23 -05:00
Adam Stokes 477dc6d783 Merge pull request #36 from CanonicalLtd/update-makefile-topdir
Update topdir Makefile targets
2015-09-01 11:13:47 -04:00
Ryan Harper 8d678ad353 Update topdir Makefile targets
A number of changes to the toplevel make file and dir structure.

- deb-src and deb-release fail because debian was a symlink.  This is not allowed
  so instead we git clone and then move the debian dir to the toplevel.
- Fix the clean target to only run rules/debian if the debian dir exists.
- Drop probert as a submodule and instead clone it as needed, controlling the
  version through a Makefile variable.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-09-01 10:04:24 -05:00
Adam Stokes 73a91728bc add more statusbar notifications
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-31 12:03:53 -04:00
Adam Stokes d149a0c014 Additional UI notifications and consolidate common attrs
We now pass a common dictionary with attributes needed
throughout our controllers. The common dictionary now
contains:

- eventloop
- ui widgets
- signal handler
- prober options
- cli arguments

In addition we've extended the progress indicator to
include a progressbar.

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-31 11:55:46 -04:00
Adam Stokes cd14fb2bdb Use our signal class emitter
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-31 10:50:59 -04:00
Adam Stokes 4ff83aa99e add another machine json
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-31 09:37:39 -04:00
Adam Stokes e1739bb615 View progress output after identity panel
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-28 20:08:30 -04:00
Adam Stokes 8ac84169f5 fix lint warning
Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-28 19:40:14 -04:00
Adam Stokes f5444088ee Merge pull request #34 from CanonicalLtd/use_human_units_everywhere
Fix issue with partition size inputs and units
2015-08-28 16:34:45 -04:00
Ryan Harper d3b7189328 Fix issue with partition size inputs and units
There was a mismatch between what human size units we accepted
and what we matched for in the view validator.  Fix that by
ensuring all places use the HUMAN_BYTES variable, including building
the multiplier from the listed HUMAN_BYTES.

Also drop the use of mixed case for the units, now all size units
must be capital (B, K, M, G, T, P) etc.

Signed-off-by: Ryan Harper <ryan.harper@canonical.com>
2015-08-28 15:30:34 -05:00
Adam Stokes d78b255b0b Extend string editor to clear out on error
During an input error the text field will be set
with the error of the validation performed.

When a user places the cursor anywhere on that error
and begins typing it will zero out the error and let
you type without having to do any previous deleting,
backspacing, etc.

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>
2015-08-28 15:50:17 -04:00
Adam Stokes 6c18ad1697 Merge pull request #32 from CanonicalLtd/read_probert_data_from_file
Add new cli option to read machine probe data from file
2015-08-28 14:25:38 -04:00