75 Commits

Author SHA1 Message Date
James Valleroy
e5b32aa6b4
Add TODO for confusing firstboot step id
Update changelog.
2017-01-02 15:05:27 -05:00
fonfon
e1aa78d25a
Firstboot, KVStore: merge old firstboot state fields
- use a migration to merge the old 'firstboot_state' and 'setup_state'
  fields into 'firstboot_completed' which is a more accurate name
- introduce kvstore.delete()
2017-01-02 15:05:24 -05:00
fonfon
3af82ab14e
Firstboot: minor variable renaming and cleanup 2017-01-02 15:05:20 -05:00
James Valleroy
9da23fa560
firstboot: Only add steps from modules if they have completed setup 2016-12-04 15:24:54 -05:00
Sunil Mohan Adapa
f457a0bdd3
first_boot: Fix various issues and refactor
- Fix major regression so that steps can submitted multiple times in
  case of errors.

- Don't serve the welcome page (and other pages) only once.  Show it
  until action is an taken.  This does not apply to the final step.

- Eliminate all coupling of one first boot step on another.

- Move first boot helper methods to __init__.py instead of middleware as
  it is more generic than middleware.

- Implement caching the first boot state to avoid an SQL query on every
  page load.  The down side is that if first boot state is modified in
  the backend DB outside Plinth, Plinth will need to be restarted to
  catch the modified value.

- Mark some methods as private.

- Refactor middleware code for slightly more simplicity.

- Don't show sidebar in pagekite first boot step.  Set width like other
  pages.
2016-12-04 15:24:48 -05:00
Sunil Mohan Adapa
56686b7148
firstboot: Rename views/urls to be non-numeric 2016-12-04 15:24:36 -05:00
Sunil Mohan Adapa
c37aa0fbd5
firstboot: Indentation & styling fixes
pycodestyle version used is 2.1.0 with default arguments.
2016-12-04 15:24:31 -05:00
James Valleroy
cf0e8219af
Use new setup state in template tag 2016-11-03 22:32:17 -04:00
Hemanth Kumar Veeranki
6011a7adfa
Made Suggested Changes 2016-11-03 22:06:08 -04:00
Hemanth Kumar Veeranki
0290f68ae6
Removed redirection for login and help urls
Changed the redirection in state0 template
2016-11-03 22:06:05 -04:00
Hemanth Kumar Veeranki
0332d4489e
Added code for modules to register for first_boot #529 2016-11-03 22:06:00 -04:00
Sunil Mohan Adapa
e719966c4b
users: Refactor valid user name checking for reuse
- Supress output from getent

- More accurate message
2016-08-12 19:32:19 +05:30
James Valleroy
c8c6bc377b
users: Add list of restricted usernammes
List is derived from optional services installed.
2016-08-12 18:48:16 +05:30
James Valleroy
3a69958165
users: Avoid username conflicts with system users
When creating or renaming a user, check if the new username is in use by
any system user.
2016-08-12 18:47:52 +05:30
Sunil Mohan Adapa
18996b5c56
Import urlresolvers from django.urls
In Django 1.10, django.core.urlresolvers is available from
django.urls. Use it.
2016-08-11 18:03:00 -04:00
Sunil Mohan Adapa
09ba42aa7c
Replace render_to_response() with render()
In Django 1.10, render_to_response no longer has context_instance
argument.  It's use is not recommended anyway.  Replace it with render()
method.
2016-08-11 18:02:52 -04:00
Sunil Mohan Adapa
2afae80dd8
security: Recommend/notify about restricted logins
- Do stricter matches when editing configuration file.  Earlier
  mechanism would match comments etc.

- Move action methods to module core from views.

- During first boot, notify users that console login is restricted and
  that they can changed that from security settings.

- Recommend enabling conosle login restrictions.  Add message about why
  console restrictions are important.

- Show title in security module.
2016-07-09 22:42:20 +05:30
James Valleroy
82c27aabf3
first_boot: Enable restricted console logins 2016-07-09 22:41:53 +05:30
Sunil Mohan Adapa
c3c44ab379
firstboot: Minor Danube PageKite fixes
- Fix message internationalization with formatting and laziness.

- Styling fixes.

- Simplify Subdomain widget.

- Update messages for grammer and consistency.
2016-03-13 23:32:26 +05:30
fonfon
435f980c6f
firstboot: freedombox.me pagekite vouchers
- Show PageKite voucher only if cfg.danube_edition is enabled
2016-03-13 23:32:20 +05:30
Sunil Mohan Adapa
60c4c17f94
firstboot: Use new setup mechanism 2016-02-13 13:52:29 +05:30
Caly
15312fe595
Update messages for simplicity/consistency/grammer
- Closes #375 and #380.

- More use of configurable brand name.
2016-01-24 12:14:25 +05:30
Sunil Mohan Adapa
4602c5bfce
Use translated brand name in templates
Using brand name directly from configuration means that it can't be
easily translated.  Instead use the translated brand name sent in my the
context processor.
2016-01-24 00:37:01 +05:30
Sunil Mohan Adapa
96f9fee96b
firstboot: Fix double nested navbar 2015-12-30 01:10:45 +05:30
Sunil Mohan Adapa
0464ac83d8
firstboot: Add doc strings for custom tags 2015-12-30 01:10:09 +05:30
fonfon
56e1b4ae57
firstboot: removed link to 'Applications'
minor bugfix - the icon wasn't displayed but the link and hover effect
were still there.
2015-12-30 01:09:13 +05:30
fonfon
0f742d704b
firstboot: Dont show normal mainmenu in help pages
- plus some minor adaptions like titles and using cfg.box_name
2015-12-30 01:08:43 +05:30
fonfon
74f64123b3 first-boot: state10: change text and layout
Instead of the buttons there is now only one link in the text for the
network setup.
2015-12-22 10:46:56 +05:30
fonfon
77e74746f0 first-boot: state1: fix focusing on form element 2015-12-22 10:38:30 +05:30
fonfon
23aee97ea9 first-boot: state0: update text and button 2015-12-22 10:38:26 +05:30
fonfon
6ee545023d first-boot: use a common navbar
- Also hide the applications icon in the second step while keeping the
  logo.
2015-12-22 10:05:37 +05:30
Philippe Baret
2037a273b3 Edited string
LDAP mention to delete (https://github.com/freedombox/Plinth/issues/347)
2015-12-19 13:36:47 -05:00
Sunil Mohan Adapa
a69f419c3c Make Django urlpatterns list of url()s
- Support for legacy pattern() mechanism will be removed in Django
  1.10.  Currently we see a warning for each Plinth module.
2015-12-05 09:33:23 -05:00
Sunil Mohan Adapa
3df1a88824 Switch to Django i18n for code strings
Django i18n layer is on top of gettext and provide may crucial features
such as per-request locales, lazy translations etc.
2015-11-13 22:08:43 +05:30
Sunil Mohan Adapa
02cd89b60d Internationalize strings in template files 2015-11-13 22:02:17 +05:30
Sunil Mohan Adapa
20d4d32153 firstboot: Show network diagram at the end
- Fix an issue with not showing message in state 1 (no messages to show
  as of now).

- Provide options to go to Applications or Network configuration page as
  discussed in first boot redesign.
2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
11bf585025 networks: Show network diagram
- As discussed in the first boot redesign proposal.

- Images are taken from Tango icon set, GNOME icons or created.

- Responsive, works for very small widths also.

- First cut, special cases of network connectivity are not handled.
2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
8228440319 first_boot: Allow accessing help during first boot 2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
8fb6e31e9a first_boot: Remove login from account creation 2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
26737293e4 first_boot: Reduce the width of administrator form 2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
5cd1b7e4b3 first_boot: Remove sidebar in favor of help icon 2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
f3a0c70d23 first_boot: Add separate greeting page 2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
23eb40fce8 first_boot: Require password confirmation
- Use existing UserCreationForm from auth module.

- Use cleaned data for login.
2015-10-28 20:02:56 -04:00
Sunil Mohan Adapa
62185a5960 first_boot: Don't ask for a new hostname
- Setting a new hostname is not one of the most buring issues to be take
  care of during the setup process.

- Also, most likely the user will access the FreedomBox machine using
  mDNS hostname such as freedombox.local.  Changing the hostname mid
  setup might have consequences that need to thought about properly.
2015-10-28 20:02:56 -04:00
fonfon
a94dc0f57d firstboot: remove deprecated CSS 2015-09-29 09:15:37 +05:30
James Valleroy
7a464d6f5f first_boot: Switch to new ldap action. 2015-07-26 16:34:29 -04:00
James Valleroy
d144f6634a Bug fixes:
Check if ejabberd is installed when running actions triggered by signals.
Encode LDAP passwords as bytes.
2015-07-23 22:30:50 +05:30
James Valleroy
cb7c9c26f7 Send LDAP user passwords to actions through stdin, not as arguments. 2015-07-23 22:30:50 +05:30
James Valleroy
86580c9121 Revert "Don't print LDAP user passwords in log."
This reverts commit b1c9c81d58c80d6b313dd2b8a5c5727ecdf6ac49.

Conflicts:
	plinth/modules/first_boot/forms.py
2015-07-23 22:30:50 +05:30
Sunil Mohan Adapa
f35d4257c2 users: Improve Django group handling with LDAP
- Create groups on first boot a bit more safely

- Use get_or_create instead of get() and create()

- Fix issue with not showing a full list of groups in user modify page
  when there is are no users for that group.
2015-07-18 17:17:07 +05:30