Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mkimage-profiles
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Anton Palgunov
mkimage-profiles
Commits
53609921
Commit
53609921
authored
Mar 05, 2014
by
Michael Shigorin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
deflogin: minor tweaks
Defining a one-time variable is useless in this case, and README should state the undefined ROOTPW status explicitly (since it's now as advertized, heh).
parent
0fcb4915
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
README
features.in/deflogin/README
+1
-0
50-root
features.in/deflogin/rootfs/image-scripts.d/50-root
+1
-3
No files found.
features.in/deflogin/README
View file @
53609921
Эта фича конфигурирует root login и пользователей по умолчанию.
Если ROOTPW не задан, то подходящий пароль не существует.
ВНИМАНИЕ: применяйте разумно, т.к. крайне легко создать и оставить
дыру в безопасности!
features.in/deflogin/rootfs/image-scripts.d/50-root
View file @
53609921
#!/bin/sh
# set root password if any; no-op if it is unset
test
=
"
${
GLOBAL_ROOTPW
=
:unset
}
"
if
[
"
$test
"
=
":unset"
]
;
then
if
[
"
${
GLOBAL_ROOTPW
=
:unset
}
"
=
":unset"
]
;
then
echo
"** warning: no root password provided, you're on your own"
>
&2
else
echo
"
$GLOBAL_ROOTPW
"
| passwd
--stdin
root
...
...
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