Merge pull request #257 from gmkurtzer/various_relocation_fixes
Various relocation fixes
This commit is contained in:
7
Makefile
7
Makefile
@@ -136,7 +136,6 @@ files: all
|
||||
install -d -m 0755 $(DESTDIR)$(WWCHROOTDIR)
|
||||
install -d -m 0755 $(DESTDIR)$(WWPROVISIONDIR)
|
||||
install -d -m 0755 $(DESTDIR)$(WWOVERLAYDIR)
|
||||
install -d -m 0755 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/bin/
|
||||
install -d -m 0755 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/warewulf/bin/
|
||||
install -d -m 0755 $(DESTDIR)$(SYSCONFDIR)/warewulf/
|
||||
install -d -m 0755 $(DESTDIR)$(SYSCONFDIR)/warewulf/ipxe
|
||||
@@ -152,6 +151,7 @@ files: all
|
||||
cp -r etc/ipxe $(DESTDIR)$(SYSCONFDIR)/warewulf/
|
||||
cp -r overlays/* $(DESTDIR)$(WWOVERLAYDIR)/
|
||||
chmod 755 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/init
|
||||
chmod 755 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/warewulf/wwinit
|
||||
chmod 600 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/etc/ssh/ssh*
|
||||
chmod 644 $(DESTDIR)$(WWOVERLAYDIR)/wwinit/etc/ssh/ssh*.pub.ww
|
||||
install -m 0755 wwctl $(DESTDIR)$(BINDIR)
|
||||
@@ -177,10 +177,11 @@ wwctl:
|
||||
cd cmd/wwctl; GOOS=linux go build -mod vendor -tags "$(WW_BUILD_GO_BUILD_TAGS)" -o ../../wwctl
|
||||
|
||||
wwclient:
|
||||
cd cmd/wwclient; CGO_ENABLED=0 GOOS=linux go build -mod vendor -a -ldflags '-extldflags -static' -o ../../wwclient
|
||||
cd cmd/wwclient; CGO_ENABLED=0 GOOS=linux go build -mod vendor -a -ldflags "-extldflags -static \
|
||||
-X 'github.com/hpcng/warewulf/internal/pkg/warewulfconf.ConfigFile=/etc/warewulf/warewulf.conf'" -o ../../wwclient
|
||||
|
||||
install_wwclient: wwclient
|
||||
install -m 0755 wwclient $(DESTDIR)$(WWOVERLAYDIR)/wwinit/bin/wwclient
|
||||
install -m 0755 wwclient $(DESTDIR)$(WWOVERLAYDIR)/wwinit/warewulf/bin/wwclient
|
||||
|
||||
|
||||
bash_completion:
|
||||
|
||||
@@ -5,14 +5,18 @@ import (
|
||||
"path"
|
||||
"strings"
|
||||
|
||||
"github.com/hpcng/warewulf/internal/pkg/buildconfig"
|
||||
"github.com/hpcng/warewulf/internal/pkg/container"
|
||||
"github.com/hpcng/warewulf/internal/pkg/util"
|
||||
"github.com/hpcng/warewulf/internal/pkg/wwlog"
|
||||
)
|
||||
|
||||
func templateFileInclude(path string) string {
|
||||
wwlog.Printf(wwlog.DEBUG, "Including file into template: %s\n", path)
|
||||
content, err := ioutil.ReadFile(path)
|
||||
func templateFileInclude(inc string) string {
|
||||
if !strings.HasPrefix(inc, "/") {
|
||||
inc = path.Join(buildconfig.SYSCONFDIR(), "warewulf", inc)
|
||||
}
|
||||
wwlog.Printf(wwlog.DEBUG, "Including file into template: %s\n", inc)
|
||||
content, err := ioutil.ReadFile(inc)
|
||||
if err != nil {
|
||||
wwlog.Printf(wwlog.VERBOSE, "Could not include file into template: %s\n", err)
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_dsa_key.pub"}}
|
||||
{{Include "keys/ssh_host_dsa_key.pub"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_dsa_key"}}
|
||||
{{Include "keys/ssh_host_dsa_key"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_ecdsa_key.pub"}}
|
||||
{{Include "keys/ssh_host_ecdsa_key.pub"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_ecdsa_key"}}
|
||||
{{Include "keys/ssh_host_ecdsa_key"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_ed25519_key.pub"}}
|
||||
{{Include "keys/ssh_host_ed25519_key.pub"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_ed25519_key"}}
|
||||
{{Include "keys/ssh_host_ed25519_key"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_rsa_key.pub"}}
|
||||
{{Include "keys/ssh_host_rsa_key.pub"}}
|
||||
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/keys/ssh_host_rsa_key"}}
|
||||
{{Include "keys/ssh_host_rsa_key"}}
|
||||
|
||||
@@ -6,8 +6,4 @@ IPADDR={{$.NetDevs.default.Ipaddr}}
|
||||
NETMASK={{$.NetDevs.default.Netmask}}
|
||||
GATEWAY={{$.NetDevs.default.Gateway}}
|
||||
HWADDR={{$.NetDevs.default.Hwaddr}}
|
||||
{{- if $.NetDevs.default.OnBoot}}
|
||||
ONBOOT=yes
|
||||
{{- else}}
|
||||
ONBOOT=no
|
||||
{{- end}}
|
||||
ONBOOT=yes
|
||||
@@ -1 +1 @@
|
||||
{{Include "/etc/warewulf/warewulf.conf"}}
|
||||
{{Include "warewulf.conf"}}
|
||||
|
||||
Reference in New Issue
Block a user