Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mailinabox
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
mailinabox
Commits
4e6d572d
Commit
4e6d572d
authored
Sep 26, 2014
by
Joshua Tauberer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ensure Python operates in UTF-8 with a consistent locale for all users
fixes #206 (hopefully)
parent
145186a6
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
0 deletions
+18
-0
management-initscript
conf/management-initscript
+9
-0
functions.sh
setup/functions.sh
+9
-0
No files found.
conf/management-initscript
View file @
4e6d572d
...
...
@@ -25,6 +25,15 @@ SCRIPTNAME=/etc/init.d/$NAME
START
=
yes
EXEC_AS_USER
=
root
# Ensure Python reads/writes files in UTF-8. If the machine
# triggers some other locale in Python, like ASCII encoding,
# Python may not be able to read/write files. Here and in
# setup/functions.sh.
export
LANGUAGE
=
en_US.UTF-8
export
LC_ALL
=
en_US.UTF-8
export
LANG
=
en_US.UTF-8
export
LC_TYPE
=
en_US.UTF-8
# Read configuration variable file if it is present
[
-r
/etc/default/
$NAME
]
&&
.
/etc/default/
$NAME
...
...
setup/functions.sh
View file @
4e6d572d
# Ensure Python reads/writes files in UTF-8. If the machine
# triggers some other locale in Python, like ASCII encoding,
# Python may not be able to read/write files. Here and in
# the management daemon startup script.
export
LANGUAGE
=
en_US.UTF-8
export
LC_ALL
=
en_US.UTF-8
export
LANG
=
en_US.UTF-8
export
LC_TYPE
=
en_US.UTF-8
function
hide_output
{
# This function hides the output of a command unless the command fails
# and returns a non-zero exit code.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment