diff options
author | torben | 2016-03-24 19:44:37 +0100 |
---|---|---|
committer | torben | 2016-03-24 19:44:37 +0100 |
commit | ee84e2165c2eb0d49c59a3d6faa75b195229438c (patch) | |
tree | a2ca50734079684c7e461763e266e10a831bacc4 /dev-tools | |
parent | Improve tar gz module. (diff) | |
download | systemd-init-ee84e2165c2eb0d49c59a3d6faa75b195229438c.tar.gz systemd-init-ee84e2165c2eb0d49c59a3d6faa75b195229438c.tar.xz systemd-init-ee84e2165c2eb0d49c59a3d6faa75b195229438c.zip |
Fix example module.
Diffstat (limited to 'dev-tools')
-rwxr-xr-x | dev-tools/exampleDracutModule/apply-package.sh | 3 | ||||
-rw-r--r-- | dev-tools/exampleDracutModule/example.service | 10 | ||||
-rwxr-xr-x | dev-tools/exampleDracutModule/module-setup.sh | 3 |
3 files changed, 14 insertions, 2 deletions
diff --git a/dev-tools/exampleDracutModule/apply-package.sh b/dev-tools/exampleDracutModule/apply-package.sh index 67bcf665..07d3c0a5 100755 --- a/dev-tools/exampleDracutModule/apply-package.sh +++ b/dev-tools/exampleDracutModule/apply-package.sh @@ -17,7 +17,6 @@ exceptions.try exceptions.activate logging.info 'Getting package.' - mkdir --parents /tmp/slx_config IFS_backup="$IFS" IFS=',' for host in ${slx_server}; do @@ -25,7 +24,7 @@ exceptions.try if wget --timeout 5 \ "http://${host}/${slx_server_base}config.tar.gz" \ --output-document - | tar --extract --verbose --gzip --directory \ - /tmp/slx_config + "$NEWROOT" then break fi diff --git a/dev-tools/exampleDracutModule/example.service b/dev-tools/exampleDracutModule/example.service new file mode 100644 index 00000000..83310c1d --- /dev/null +++ b/dev-tools/exampleDracutModule/example.service @@ -0,0 +1,10 @@ +[Unit] +Description=Simple example service +After=dracut-pre-mount.service network.target +DefaultDependencies=no + +[Service] +Type=oneshot +RemainAfterExit=true +KillMode=none +ExecStart=/usr/bin/bash -c '/usr/bin/echo test >/tmp/test-output.txt' diff --git a/dev-tools/exampleDracutModule/module-setup.sh b/dev-tools/exampleDracutModule/module-setup.sh index 1604fd3f..af9bda6c 100755 --- a/dev-tools/exampleDracutModule/module-setup.sh +++ b/dev-tools/exampleDracutModule/module-setup.sh @@ -14,6 +14,9 @@ check() { `check` ' + + # Here we could build our package file. + # Tell dracut that this module should only be included if it is required # explicitly. return 255 |