chore: Initialize sshappbackend.
This commit is contained in:
parent
4101ce7007
commit
a35602a6f2
4 changed files with 54 additions and 17 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
@ -1,8 +1,10 @@
|
||||||
# Go artifacts
|
# Go artifacts
|
||||||
|
backend/api/api
|
||||||
backend/sshbackend/sshbackend
|
backend/sshbackend/sshbackend
|
||||||
backend/dummybackend/dummybackend
|
backend/dummybackend/dummybackend
|
||||||
|
backend/sshappbackend/remote-code/bin
|
||||||
|
backend/sshappbackend/local-code/sshappbackend
|
||||||
backend/externalbackendlauncher/externalbackendlauncher
|
backend/externalbackendlauncher/externalbackendlauncher
|
||||||
backend/api/api
|
|
||||||
frontend/frontend
|
frontend/frontend
|
||||||
|
|
||||||
# Backup artifacts
|
# Backup artifacts
|
||||||
|
|
|
@ -1,20 +1,41 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
pushd sshbackend
|
pushd sshbackend > /dev/null
|
||||||
GOOS=linux go build .
|
echo "building sshbackend"
|
||||||
strip sshbackend
|
go build -ldflags="-s -w" -trimpath .
|
||||||
popd
|
popd > /dev/null
|
||||||
|
|
||||||
pushd dummybackend
|
pushd dummybackend > /dev/null
|
||||||
GOOS=linux go build .
|
echo "building dummybackend"
|
||||||
strip dummybackend
|
go build -ldflags="-s -w" -trimpath .
|
||||||
popd
|
popd > /dev/null
|
||||||
|
|
||||||
pushd externalbackendlauncher
|
pushd externalbackendlauncher > /dev/null
|
||||||
go build .
|
echo "building externalbackendlauncher"
|
||||||
strip externalbackendlauncher
|
go build -ldflags="-s -w" -trimpath .
|
||||||
popd
|
popd > /dev/null
|
||||||
|
|
||||||
pushd api
|
pushd sshappbackend/remote-code > /dev/null
|
||||||
GOOS=linux go build .
|
echo "building sshappbackend/remote-code"
|
||||||
strip api
|
if [ ! -d bin ]; then
|
||||||
popd
|
mkdir bin
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo " - building for arm64"
|
||||||
|
GOOS=linux GOARCH=arm64 go build -ldflags="-s -w" -trimpath -o bin/rt-arm64 .
|
||||||
|
echo " - building for arm"
|
||||||
|
GOOS=linux GOARCH=arm go build -ldflags="-s -w" -trimpath -o bin/rt-arm .
|
||||||
|
echo " - building for amd64"
|
||||||
|
GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" -trimpath -o bin/rt-amd64 .
|
||||||
|
echo " - building for i386"
|
||||||
|
GOOS=linux GOARCH=386 go build -ldflags="-s -w" -trimpath -o bin/rt-386 .
|
||||||
|
popd > /dev/null
|
||||||
|
|
||||||
|
pushd sshappbackend/local-code > /dev/null
|
||||||
|
echo "building sshappbackend/local-code"
|
||||||
|
go build -ldflags="-s -w" -trimpath -o sshappbackend .
|
||||||
|
popd > /dev/null
|
||||||
|
|
||||||
|
pushd api > /dev/null
|
||||||
|
echo "building api"
|
||||||
|
go build -ldflags="-s -w" -trimpath .
|
||||||
|
popd > /dev/null
|
||||||
|
|
7
backend/sshappbackend/local-code/main.go
Normal file
7
backend/sshappbackend/local-code/main.go
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import "fmt"
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
fmt.Println("lokkuh code")
|
||||||
|
}
|
7
backend/sshappbackend/remote-code/main.go
Normal file
7
backend/sshappbackend/remote-code/main.go
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
import "fmt"
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
fmt.Println("remottuh code")
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue