Skip to content

Commit ad5d139

Browse files
committed
chore(PI-5921): update default API endpoint to be api.nowsecure.com
1 parent 793bbe9 commit ad5d139

8 files changed

Lines changed: 35 additions & 7 deletions

File tree

Makefile

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
NAME := nowsecure-ci
2+
BIN := ./bin/ns
3+
EXE := .
4+
5+
default: ci
6+
7+
ci: lint test dependencies-analyze
8+
9+
build:
10+
mkdir -p bin
11+
CGO_ENABLED=0 go build -ldflags="-s -w" -o $(BIN) $(EXE)
12+
13+
PACKAGES := $(shell go list ./...)
14+
15+
test:
16+
go run gotest.tools/gotestsum@latest --format testname $(PACKAGES)
17+
18+
LINTER_ARGS := "--fix"
19+
20+
lint:
21+
@which golangci-lint > /dev/null || (echo "golangci-lint not found. Run 'nix develop' or install it manually." && exit 1)
22+
golangci-lint run ${LINTER_ARGS} ./...
23+
24+
dependencies-analyze:
25+
which govulncheck || go install golang.org/x/vuln/cmd/govulncheck@latest
26+
govulncheck ./...
27+
28+
.PHONY: default ci build test lint dependencies-analyze

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ The tool provides three methods to run security assessments:
8383

8484
#### API Configuration
8585

86-
- `--api-host` - REST API base URL (default: `https://lab-api.nowsecure.com`)
86+
- `--api-host` - REST API base URL (default: `https://api.nowsecure.com`)
8787
- Use this to point to a different NowSecure endpoint if you are accessing a single tenant instance
8888

8989
- `--ui-host` - UI base URL (default: `https://app.nowsecure.com`)

cmd/ns/nowsecure.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ func RootCommand(ctx context.Context, v *viper.Viper, config *internal.BaseConfi
4747
}
4848

4949
rootCmd.PersistentFlags().StringP("config", "c", "", "config file path")
50-
rootCmd.PersistentFlags().String("api-host", "https://lab-api.nowsecure.com", "REST API base url")
50+
rootCmd.PersistentFlags().String("api-host", "https://api.nowsecure.com", "REST API base url")
5151
rootCmd.PersistentFlags().String("ui-host", "https://app.nowsecure.com", "UI base url")
5252
rootCmd.PersistentFlags().String("token", "", "auth token for REST API")
5353
rootCmd.PersistentFlags().String("group-ref", "", "group uuid with which to run assessments")

docs/cli/ns.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ NowSecure command line tool to interact with NowSecure Platform
55
### Options
66

77
```
8-
--api-host string REST API base url (default "https://lab-api.nowsecure.com")
8+
--api-host string REST API base url (default "https://api.nowsecure.com")
99
--ci-environment string appended to the user_agent header
1010
-c, --config string config file path
1111
--group-ref string group uuid with which to run assessments

docs/cli/ns_run.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Run an assessment for a given application
1616
### Options inherited from parent commands
1717

1818
```
19-
--api-host string REST API base url (default "https://lab-api.nowsecure.com")
19+
--api-host string REST API base url (default "https://api.nowsecure.com")
2020
--ci-environment string appended to the user_agent header
2121
-c, --config string config file path
2222
--group-ref string group uuid with which to run assessments

docs/cli/ns_run_file.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ ns run file ./path/to/binary \
4545

4646
```
4747
--analysis-type string One of: full, static, sbom (default "full")
48-
--api-host string REST API base url (default "https://lab-api.nowsecure.com")
48+
--api-host string REST API base url (default "https://api.nowsecure.com")
4949
--artifacts-dir string directory in which to put artifacts (default "$PWD")
5050
--ci-environment string appended to the user_agent header
5151
-c, --config string config file path

docs/cli/ns_run_id.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ ns run id [app-id] \
4545

4646
```
4747
--analysis-type string One of: full, static, sbom (default "full")
48-
--api-host string REST API base url (default "https://lab-api.nowsecure.com")
48+
--api-host string REST API base url (default "https://api.nowsecure.com")
4949
--artifacts-dir string directory in which to put artifacts (default "$PWD")
5050
--ci-environment string appended to the user_agent header
5151
-c, --config string config file path

docs/cli/ns_run_package.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ ns run package [package-name] \
5151

5252
```
5353
--analysis-type string One of: full, static, sbom (default "full")
54-
--api-host string REST API base url (default "https://lab-api.nowsecure.com")
54+
--api-host string REST API base url (default "https://api.nowsecure.com")
5555
--artifacts-dir string directory in which to put artifacts (default "$PWD")
5656
--ci-environment string appended to the user_agent header
5757
-c, --config string config file path

0 commit comments

Comments
 (0)