From 0b10ef77deaf8cca8948ea6411b4a7ad3a2f6ac1 Mon Sep 17 00:00:00 2001 From: Rui Chen Date: Mon, 8 Jul 2024 09:59:46 -0400 Subject: [PATCH] chore: bump version to 0.3.7 Signed-off-by: Rui Chen --- .env.example | 2 +- deploy/docker/README.md | 68 ++++++++++++++--------------- deploy/docker/conf/dev/.env.example | 2 +- osctrl-api.yaml | 2 +- version/version.go | 2 +- version/version_test.go | 2 +- 6 files changed, 39 insertions(+), 39 deletions(-) diff --git a/.env.example b/.env.example index 527a988a..b7c1da35 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,4 @@ -OSCTRL_VERSION=0.3.6 +OSCTRL_VERSION=0.3.7 OSQUERY_VERSION=5.12.1 NGINX_VERSION=1.21.6-alpine POSTGRES_VERSION=13.5-alpine diff --git a/deploy/docker/README.md b/deploy/docker/README.md index 8a9f5eab..56fcfa80 100644 --- a/deploy/docker/README.md +++ b/deploy/docker/README.md @@ -1,6 +1,6 @@ # osctrl Docker dev environment -This directory contains all the necessary configs to setup the osctrl Docker dev environment. There a couple of manual steps that are required before having a fully functional deployment: +This directory contains all the necessary configs to setup the osctrl Docker dev environment. There a couple of manual steps that are required before having a fully functional deployment: 1. Generate TLS/SSL termination certificate and private key 2. Generate JWT secret for API tokens @@ -11,61 +11,61 @@ Follow these steps to generate a self-signed certificate that is going to be use 1. `cp conf/tls/openssl.cnf.example conf/tls/openssl.cnf` 2. `BASE_DOMAIN= openssl req -x509 -new -nodes -days ` with an a domain like `osctrl.example.com` - 2. ![docker_openssl_generate](../../.img/docker_openssl_generate.png) + 1. Replace `` with an a domain like `osctrl.example.com` + 2. ![docker_openssl_generate](../../.img/docker_openssl_generate.png) ## Generate JWT secret You can generate a random enough JWT secret to be used with the `osctrl-api` and `osctrl-admin` components using one of the following commands: 1. `uuidgen | shasum -a 256 | awk '{print $1}'` - 1. ![docker_uuid_gen](../../.img/docker_uuid_gen.png) + 1. ![docker_uuid_gen](../../.img/docker_uuid_gen.png) 2. `vim .env` and set `JWT_SECRET` ## Set .env 1. `cp .env.example .env` 2. `vim .env` and set: - 1. osctrl - 1. `OSCTRL_VERSION` - define the version of osctrl to use - 2. `JWT_SECRET` - define the JWT secret (see instructions above) - 3. `OSCTRL_USER` - define username for osctrl admin user - 4. `OSCTRL_PASS` - define password for osctrl admin user - 2. osquery - 1. `OSQUERY_VERSION` - define the version of Osquery for test instance - 3. NGINX - 1. `NGINX_VERSION` - define the version of NGINX to use - 4. Postgres - 1. `POSTGRES_VERSION` - define the version of Postgres to use - 2. `POSTGRES_DB_NAME` - define the name of the database for osctrl - 3. `POSTGRES_DB_USERNAME` - define the username to conenct to osctrl database - 4. `POSTGRES_DB_PASSWORD` - define the password to conenct to osctrl database - 5. Save and exit + 1. osctrl + 1. `OSCTRL_VERSION` - define the version of osctrl to use + 2. `JWT_SECRET` - define the JWT secret (see instructions above) + 3. `OSCTRL_USER` - define username for osctrl admin user + 4. `OSCTRL_PASS` - define password for osctrl admin user + 2. osquery + 1. `OSQUERY_VERSION` - define the version of Osquery for test instance + 3. NGINX + 1. `NGINX_VERSION` - define the version of NGINX to use + 4. Postgres + 1. `POSTGRES_VERSION` - define the version of Postgres to use + 2. `POSTGRES_DB_NAME` - define the name of the database for osctrl + 3. `POSTGRES_DB_USERNAME` - define the username to conenct to osctrl database + 4. `POSTGRES_DB_PASSWORD` - define the password to conenct to osctrl database + 5. Save and exit 3. `docker-compose build` - 1. Build Docker images + 1. Build Docker images 4. `docker-compose up` - 1. Spin up osctrl Docker stack + 1. Spin up osctrl Docker stack ## Login into osctrl 1. Open a browser to `https://127.0.0.1:8443/login` 2. Login - 1. Enter `` for username - 2. Enter `` for password + 1. Enter `` for username + 2. Enter `` for password ## References -* [What is osctrl?](https://osctrl.net/) -* [osctrl-api](https://app.swaggerhub.com/apis-docs/jmpsec/osctrl-api/0.3.6#/) +- [What is osctrl?](https://osctrl.net/) +- [osctrl-api](https://app.swaggerhub.com/apis-docs/jmpsec/osctrl-api/0.3.7#/) ### Docker -* [How to create new users in a Docker container?](https://net2.com/how-to-create-new-users-in-docker-container/) -* [Is mkdir -p totally safe when creating folder already exists](https://unix.stackexchange.com/questions/242995/is-mkdir-p-totally-safe-when-creating-folder-already-exists) -* [Meaning of ampersand (&) in docker-compose.yml file](https://stackoverflow.com/questions/45805380/meaning-of-ampersand-in-docker-compose-yml-file) -* [ChooseYourSIEMAdventure/docker-compose-splunk.yml](https://github.com/CptOfEvilMinions/ChooseYourSIEMAdventure/blob/main/docker-compose-splunk.yml) -* [Interactive shell using Docker Compose](https://stackoverflow.com/questions/36249744/interactive-shell-using-docker-compose) -* [Advanced Dockerfiles: Faster Builds and Smaller Images Using BuildKit and Multistage Builds](https://www.docker.com/blog/advanced-dockerfiles-faster-builds-and-smaller-images-using-buildkit-and-multistage-builds/) -* [Using openssl to get the certificate from a server](https://stackoverflow.com/questions/7885785/using-openssl-to-get-the-certificate-from-a-server) -* [osquery flags](https://osquery.readthedocs.io/en/stable/installation/cli-flags/) -* [mkcert is a simple tool for making locally-trusted development certificates](https://github.com/FiloSottile/mkcert) +- [How to create new users in a Docker container?](https://net2.com/how-to-create-new-users-in-docker-container/) +- [Is mkdir -p totally safe when creating folder already exists](https://unix.stackexchange.com/questions/242995/is-mkdir-p-totally-safe-when-creating-folder-already-exists) +- [Meaning of ampersand (&) in docker-compose.yml file](https://stackoverflow.com/questions/45805380/meaning-of-ampersand-in-docker-compose-yml-file) +- [ChooseYourSIEMAdventure/docker-compose-splunk.yml](https://github.com/CptOfEvilMinions/ChooseYourSIEMAdventure/blob/main/docker-compose-splunk.yml) +- [Interactive shell using Docker Compose](https://stackoverflow.com/questions/36249744/interactive-shell-using-docker-compose) +- [Advanced Dockerfiles: Faster Builds and Smaller Images Using BuildKit and Multistage Builds](https://www.docker.com/blog/advanced-dockerfiles-faster-builds-and-smaller-images-using-buildkit-and-multistage-builds/) +- [Using openssl to get the certificate from a server](https://stackoverflow.com/questions/7885785/using-openssl-to-get-the-certificate-from-a-server) +- [osquery flags](https://osquery.readthedocs.io/en/stable/installation/cli-flags/) +- [mkcert is a simple tool for making locally-trusted development certificates](https://github.com/FiloSottile/mkcert) diff --git a/deploy/docker/conf/dev/.env.example b/deploy/docker/conf/dev/.env.example index 6823eff6..9e05d8a4 100644 --- a/deploy/docker/conf/dev/.env.example +++ b/deploy/docker/conf/dev/.env.example @@ -1,4 +1,4 @@ -OSCTRL_VERSION=0.3.6 +OSCTRL_VERSION=0.3.7 OSQUERY_VERSION=5.12.1 NGINX_VERSION=1.21.6-alpine POSTGRES_VERSION=13.5-alpine diff --git a/osctrl-api.yaml b/osctrl-api.yaml index 17b44598..9b5f63d7 100644 --- a/osctrl-api.yaml +++ b/osctrl-api.yaml @@ -7,7 +7,7 @@ servers: info: title: osctrl-api description: "This the API for osctrl, a fast and efficient osquery management solution." - version: 0.3.6 + version: 0.3.7 externalDocs: description: osctrl documentation url: https://osctrl.net diff --git a/version/version.go b/version/version.go index 760718d8..12ddea0e 100644 --- a/version/version.go +++ b/version/version.go @@ -2,7 +2,7 @@ package version const ( // OsctrlVersion to have the version for all components - OsctrlVersion = "0.3.6" + OsctrlVersion = "0.3.7" // OsqueryVersion to have the version for osquery defined OsqueryVersion = "5.12.1" ) diff --git a/version/version_test.go b/version/version_test.go index 00469382..e55920a6 100644 --- a/version/version_test.go +++ b/version/version_test.go @@ -11,5 +11,5 @@ func TestOsqueryVersion(t *testing.T) { } func TestOsctrlVersion(t *testing.T) { - assert.Equal(t, "0.3.6", OsctrlVersion) + assert.Equal(t, "0.3.7", OsctrlVersion) }