Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
systemd
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
steam
systemd
Commits
81253930
Commit
81253930
authored
Mar 08, 2011
by
Lennart Poettering
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
job: convert job type as early as we can, to simplify things a bit
parent
85f0c93a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
11 deletions
+21
-11
TODO
TODO
+10
-8
src/job.c
src/job.c
+11
-3
No files found.
TODO
View file @
81253930
...
...
@@ -14,11 +14,19 @@ F15:
* hook emergency.target into local-fs.target in some way as OnFailure with isolate
* libudev is borked regarding tags
* introduce simple way to do mandatory conditions (make current conditions mandatory, and introduce =| as non-mandatory conditions)
* mount /dev/.run and /var/run as bind mounts
* Make use of UnknownInterface, UnknownObject
* verify SYSTEMD_IGNORE_DEPENDENCIES support in /etc/rc.d/functions
Features:
* mount /dev/.run and /var/run as bind mounts
* consider services with no [Install] section and stored in /lib enabled by "systemctl is-enabled"
* consider services with any kind of link in /etc/systemd/system enabled
* introduce "x-systemd-automount" as alternative to the "comment=systemd.automount" mount option
...
...
@@ -30,18 +38,12 @@ Features:
document it? When doing that add switch to make this temporary by
placing mask links in /dev.
* introduce simple way to do mandatory conditions (make current conditions mandatory, and introduce =| as non-mandatory conditions)
* detect LXC environment
* invoke vhangup() before and after invoking getty
* support "auto" and "comment=systemd.automount" at the same time for an fstab entry
* Make use of UnknownInterface, UnknownObject
* look up crypto partition mount points via fstab to show to the user when prompting for a password
* Maybe store in unit files whether a service should be enabled by default on package installation
* perhaps add "systemctl reenable" as combination of "systemctl disable" and "systemctl enable"
...
...
src/job.c
View file @
81253930
...
...
@@ -422,10 +422,16 @@ int job_run_and_invalidate(Job *j) {
break
;
case
JOB_RELOAD_OR_START
:
if
(
unit_active_state
(
j
->
unit
)
==
UNIT_ACTIVE
)
if
(
unit_active_state
(
j
->
unit
)
==
UNIT_ACTIVE
)
{
j
->
type
=
JOB_RELOAD
;
r
=
unit_reload
(
j
->
unit
);
else
}
else
{
j
->
type
=
JOB_START
;
r
=
unit_start
(
j
->
unit
);
if
(
r
==
-
EBADR
)
r
=
0
;
}
break
;
case
JOB_RESTART
:
{
...
...
@@ -445,8 +451,10 @@ int job_run_and_invalidate(Job *j) {
else
if
(
t
==
UNIT_ACTIVATING
)
{
j
->
type
=
JOB_START
;
r
=
unit_start
(
j
->
unit
);
}
else
}
else
{
j
->
type
=
JOB_RESTART
;
r
=
unit_stop
(
j
->
unit
);
}
break
;
}
...
...
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