I submitted a pull request to add this package to the tree: https://github.com/gentoo/gentoo/pull/2043 See also bug 590722.
Yes, I welcome this initiative very much! The original targetcli package has been unmaintained for years and suffers bit rot. The fork (targetcli-fb is maintained. Also, it is much cleaner than the original code. In order to install targetcli-fb I was forced to create a local repository. Also, I was forced to write an very simple init script for it. Please note that targetcli-fb depends on configshell-fb and rtslib-fb. My local repo looks like this: workstation ~ # cd /usr/local/portage/ workstation portage # tree . ├── dev-python │ ├── configshell-fb │ │ ├── configshell-fb-1.1.18.ebuild │ │ ├── configshell-fb-1.1.20.ebuild │ │ └── Manifest │ └── rtslib-fb │ ├── Manifest │ ├── rtslib-fb-2.1.57.ebuild │ └── rtslib-fb-2.1.60.ebuild ├── metadata │ └── layout.conf ├── profiles │ └── repo_name └── sys-block └── targetcli-fb ├── Manifest ├── targetcli-fb-2.1.41.ebuild └── targetcli-fb-2.1.43.ebuild
Created attachment 444774 [details] Very simple targetcli-fb init script This is a very simple init script I wrote for targetcli-fb. Install it in /etc/init.d The contents of /etc/conf.d/targetcli-fb are: rc_need="net.ovsbr1" TARGETCTL="/usr/bin/targetctl" TARGET_CONFIG="/etc/target/saveconfig.json"
+1 for this effort. Would it be possible to add a systemd.unit to the package? A very simple unit like the following works for me: [Unit] Description=Restore LIO kernel target configuration Requires=sys-kernel-config.mount After=sys-kernel-config.mount network.target local-fs.target [Service] Type=oneshot RemainAfterExit=yes ExecStart=/usr/bin/targetctl restore ExecStop=/usr/bin/targetctl clear SyslogIdentifier=target [Install] WantedBy=multi-user.target
(In reply to alexander haensch from comment #3) > Would it be possible to add a systemd.unit to the package? targetctl belongs to dev-python/rtslib-fb, so that's probably where the systemd unit should go.
(Same for the init script)
PR merged a while ago. Thanks!