Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
laverya committed Oct 17, 2023
1 parent d583c73 commit 9bfc651
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 7 deletions.
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,10 @@ all-ttl.sh: build-ttl.sh
docker tag rqlite/rqlite:${RQLITE_TAG} ttl.sh/${CURRENT_USER}/rqlite:${RQLITE_TAG}
docker push ttl.sh/${CURRENT_USER}/rqlite:${RQLITE_TAG}

api-ttl.sh:
docker build -f ./deploy/okteto/okteto.Dockerfile -t ttl.sh/${CURRENT_USER}/kotsadm-api:24h .
docker push ttl.sh/${CURRENT_USER}/kotsadm-api:24h

.PHONY: build-alpha
build-alpha:
docker build --pull -f deploy/Dockerfile --build-arg version=${GIT_TAG} -t kotsadm/kotsadm:alpha .
Expand Down
12 changes: 6 additions & 6 deletions deploy/okteto/okteto.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,11 @@ RUN --mount=target=$GOMODCACHE,id=kots-gomodcache,type=cache \
mv ./bin/kotsadm /kotsadm && \
mv ./bin/kots /kots

RUN --mount=target=/tmp/.cache/gocache,id=kots-gocache,type=cache \
--mount=target=/tmp/.cache/gomodcache,id=kots-gomodcache,type=cache \
mkdir -p $GOCACHE \
&& cp -r /tmp/.cache/gocache/* $GOCACHE \
&& mkdir -p $GOMODCACHE \
&& cp -r /tmp/.cache/gomodcache/* $GOMODCACHE
#RUN --mount=target=/tmp/.cache/gocache,id=kots-gocache,type=cache \
# --mount=target=/tmp/.cache/gomodcache,id=kots-gomodcache,type=cache \
# mkdir -p $GOCACHE \
# && cp -r /tmp/.cache/gocache/* $GOCACHE \
# && mkdir -p $GOMODCACHE \
# && cp -r /tmp/.cache/gomodcache/* $GOMODCACHE

ENTRYPOINT [ "/kotsadm", "api"]
10 changes: 10 additions & 0 deletions node_modules/.yarn-integrity

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion pkg/helmvm/node_join.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,10 @@ import (

// GenerateAddNodeCommand will generate the HelmVM node add command for a primary or secondary node
func GenerateAddNodeCommand(client kubernetes.Interface, primary bool) ([]string, *time.Time, error) {
return nil, nil, nil
tomorrow := time.Now().Add(time.Hour * 24)
if primary {
return []string{"this is a primary join command string", "that can be multiple strings"}, &tomorrow, nil
} else {
return []string{"this is a secondary join command string", "that can be multiple strings"}, &tomorrow, nil
}
}
2 changes: 2 additions & 0 deletions pkg/helmvm/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ func IsHelmVM(clientset kubernetes.Interface) (bool, error) {
return false, fmt.Errorf("failed to get embedded cluster configmap: %w", err)
}

fmt.Printf("Is Embedded Cluster Config found: %v\n", configMapExists)

return configMapExists, nil
}

Expand Down

0 comments on commit 9bfc651

Please sign in to comment.