Skip to content
This repository has been archived by the owner. It is now read-only.

Distinguish between environments #17

Merged
merged 5 commits into from Jun 5, 2014
Merged

Distinguish between environments #17

merged 5 commits into from Jun 5, 2014

Conversation

@fofr
Copy link
Contributor

@fofr fofr commented Jun 4, 2014

  • Distinguish between Preview and Production so that users don't accidentally make changes to Production content whilst under the assumption they're working on Preview.
  • Highlight environment using a favicon, a coloured navigation bar and a coloured label
  • Determine environment based on variable set at deploy time (see https://github.gds/gds/alphagov-deployment/pull/603 for an example)
  • Based on alphagov/publisher#203
  • Namespace new images
  • Allow apps to override default favicons

screen shot 2014-06-04 at 16 30 03

fofr added 3 commits Jun 4, 2014
* Include environment based favicons
* Set environment_style and environment_label at deploy time
* Include a development only default environment
* When no environment is set, show no indicator
* Styles pulled from publisher:
alphagov/publisher#203
* Prevent clashes with images from parent apps (eg favicons)
@bishboria
bishboria reviewed Jun 4, 2014
View changes
README.md Outdated

The gem includes default styles for development, preview and production. This includes a coloured environment label, a coloured strip beneath the main navigation and a coloured favicon. They are based on two variables that are set at deploy time (if they aren’t set no indicator will be shown).

See [publisher for an example](https://github.gds/gds/alphagov-deployment/pull/603).

This comment has been minimized.

@bishboria

bishboria Jun 4, 2014
Contributor

Anyone who can't access this site has a broken link. Just use the code example (below) on its own?

This comment has been minimized.

@alext

alext Jun 5, 2014
Contributor

What he said. Might be worth noting that the code below should be set in an initializer.

@benilovj
Copy link
Contributor

@benilovj benilovj commented Jun 5, 2014

So we're calling it it production, rather than live?

@alext
Copy link
Contributor

@alext alext commented Jun 5, 2014

@benilovj for now. The human readable label is configured in the various apps, so we can tweak easily while we experiment with what makes most sense to users.

* Be explicit about what we are expecting in the no environment test
@fofr
Copy link
Contributor Author

@fofr fofr commented Jun 5, 2014

Updated documentation and rebased.

alext added a commit that referenced this pull request Jun 5, 2014
@alext alext merged commit cade4d6 into master Jun 5, 2014
1 check passed
1 check passed
default "Build #23 succeeded on Jenkins"
Details
@alext alext deleted the distinguish-environment branch Jun 5, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.