Skip to content

Commit

Permalink
Bumps Neosync to v0.5 (#3084)
Browse files Browse the repository at this point in the history
  • Loading branch information
nickzelei authored Jan 3, 2025
2 parents a43a4e3 + 1530eba commit f0f4e54
Show file tree
Hide file tree
Showing 459 changed files with 32,358 additions and 40,341 deletions.
134 changes: 132 additions & 2 deletions .github/workflows/artifact-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
- "v*.*.*"
branches:
- main
- "develop/v[0-9].[0-9]"
paths: # path filters are not evaluated for pushes of tags
- backend/**
- cli/**
Expand All @@ -29,10 +30,26 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"

- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"

- name: Get current time
id: current-time
run: echo "CURRENT_TIME=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_OUTPUT
Expand All @@ -53,6 +70,7 @@ jobs:
type=semver,pattern={{raw}}
type=sha
type=raw,value=${{ steps.next_pre_version.outputs.version }},enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
type=raw,value=${{ steps.next_pre_version_develop.outputs.version }},enable=${{ startsWith(github.ref, 'refs/heads/develop/v') }}
- name: Login to GHCR
uses: docker/login-action@v3
Expand Down Expand Up @@ -92,9 +110,24 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"
- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
Expand All @@ -111,7 +144,7 @@ jobs:
type=semver,pattern={{raw}}
type=sha
type=raw,value=${{ steps.next_pre_version.outputs.version }},enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
type=raw,value=${{ steps.next_pre_version_develop.outputs.version }},enable=${{ startsWith(github.ref, 'refs/heads/develop/v') }}
- name: Login to GHCR
uses: docker/login-action@v3
with:
Expand Down Expand Up @@ -146,9 +179,24 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"
- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
Expand All @@ -165,7 +213,7 @@ jobs:
type=semver,pattern={{raw}}
type=sha
type=raw,value=${{ steps.next_pre_version.outputs.version }},enable=${{ github.ref == format('refs/heads/{0}', 'main') }}
type=raw,value=${{ steps.next_pre_version_develop.outputs.version }},enable=${{ startsWith(github.ref, 'refs/heads/develop/v') }}
- name: Login to GHCR
uses: docker/login-action@v3
with:
Expand Down Expand Up @@ -198,9 +246,24 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"
- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"

- name: Setup Trimmed Helm Version
run: |
Expand All @@ -211,6 +274,11 @@ jobs:
echo "$TRIMMED_VERSION"
echo "CHART_VERSION=$TRIMMED_VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=false" >> $GITHUB_ENV
elif [[ $GITHUB_REF =~ ^refs/heads/develop/v[0-9]+\.[0-9]+$ ]]; then
VERSION="${{ steps.next_pre_version_develop.outputs.version }}"
echo "$VERSION"
echo "CHART_VERSION=$VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=true" >> $GITHUB_ENV
else
VERSION="${{ steps.next_pre_version.outputs.version }}"
echo "$VERSION"
Expand Down Expand Up @@ -279,9 +347,24 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"
- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"

- name: Setup Trimmed Helm Version
run: |
Expand All @@ -292,6 +375,11 @@ jobs:
echo "$TRIMMED_VERSION"
echo "CHART_VERSION=$TRIMMED_VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=false" >> $GITHUB_ENV
elif [[ $GITHUB_REF =~ ^refs/heads/develop/v[0-9]+\.[0-9]+$ ]]; then
VERSION="${{ steps.next_pre_version_develop.outputs.version }}"
echo "$VERSION"
echo "CHART_VERSION=$VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=true" >> $GITHUB_ENV
else
VERSION="${{ steps.next_pre_version.outputs.version }}"
echo "$VERSION"
Expand Down Expand Up @@ -360,10 +448,26 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"

- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"

- name: Setup Trimmed Helm Version
run: |
if [[ $GITHUB_REF == refs/tags/* ]]; then
Expand All @@ -373,6 +477,11 @@ jobs:
echo "$TRIMMED_VERSION"
echo "CHART_VERSION=$TRIMMED_VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=false" >> $GITHUB_ENV
elif [[ $GITHUB_REF =~ ^refs/heads/develop/v[0-9]+\.[0-9]+$ ]]; then
VERSION="${{ steps.next_pre_version_develop.outputs.version }}"
echo "$VERSION"
echo "CHART_VERSION=$VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=true" >> $GITHUB_ENV
else
VERSION="${{ steps.next_pre_version.outputs.version }}"
echo "$VERSION"
Expand Down Expand Up @@ -443,10 +552,26 @@ jobs:
fetch-depth: 0
- name: Calculate Next Pre-release version
id: next_pre_version
if: github.ref == 'refs/heads/main'
uses: paulhatch/[email protected]
with:
version_format: "${major}.${minor}.${patch}-pre.${increment}"

- name: Extract develop version
id: extract_version
if: startsWith(github.ref, 'refs/heads/develop/v')
run: |
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
VERSION_NUMBER="${BRANCH_NAME#develop/v}"
echo "VERSION=$VERSION_NUMBER" >> $GITHUB_OUTPUT
- name: Calculate Next Pre-release version (develop)
id: next_pre_version_develop
if: startsWith(github.ref, 'refs/heads/develop/v')
uses: paulhatch/[email protected]
with:
version_format: "${{ steps.extract_version.outputs.VERSION }}.0-dev.${increment}"

- name: Setup Trimmed Helm Version
run: |
if [[ $GITHUB_REF == refs/tags/* ]]; then
Expand All @@ -456,6 +581,11 @@ jobs:
echo "$TRIMMED_VERSION"
echo "CHART_VERSION=$TRIMMED_VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=false" >> $GITHUB_ENV
elif [[ $GITHUB_REF =~ ^refs/heads/develop/v[0-9]+\.[0-9]+$ ]]; then
VERSION="${{ steps.next_pre_version_develop.outputs.version }}"
echo "$VERSION"
echo "CHART_VERSION=$VERSION" >> $GITHUB_ENV
echo "IS_PRERELEASE=true" >> $GITHUB_ENV
else
VERSION="${{ steps.next_pre_version.outputs.version }}"
echo "$VERSION"
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,4 @@ neosync_cloud_ca.key

.env.app.local
.env.api.local
.env.worker.local
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ compose/up: ## Composes up the production environment
compose/down: ## Composes down the production environment
docker compose -f $(PROD_COMPOSE_FILE) down

compose/auth/up: ## Composes up the production environment with auth
compose/auth/up: ## Composes up the production environment with auth - Requires a valid Neosync Enterprise license!
BUILDX_NO_DEFAULT_ATTESTATIONS=1 docker compose -f $(PROD_COMPOSE_FILE) -f $(PROD_AUTH_COMPOSE_FILE) up -d

compose/auth/down: ## Composes down the production environment with auth
Expand All @@ -127,7 +127,7 @@ compose/dev/up: ## Composes up the development environment.
compose/dev/down: ## Composes down the development environment
docker compose -f $(DEV_COMPOSE_FILE) down

compose/dev/auth/up: ## Composes up the development environment with auth.
compose/dev/auth/up: ## Composes up the development environment with auth. - Requires a valid Neosync Enterprise license!
BUILDX_NO_DEFAULT_ATTESTATIONS=1 docker compose -f $(DEV_COMPOSE_FILE) -f $(DEV_AUTH_COMPOSE_FILE) up -d

compose/dev/auth/down: ## Composes down the development environment with auth
Expand Down
2 changes: 1 addition & 1 deletion backend/charts/api/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ A Helm chart for the Neosync Backend API
| resources.limits.memory | string | `"512Mi"` | Sets the max Memory amount |
| resources.requests.cpu | string | `"100m"` | Sets the CPU amount to be requested |
| resources.requests.memory | string | `"128Mi"` | Sets the Memory amount to be requested |
| runLogs.enabled | bool | `true` | Independently set so that configuration can exist but logs can still be independently disabled. Defaults to true with k8s-pods configuration for backwards compat and because this is a helm chart this is defacto kubernetes |
| runLogs.enabled | bool | `false` | Enable this if planning to surface logs within Neosync API and UI (requires a valid license). |
| runLogs.lokiConfig.baseUrl | string | `nil` | The base url to the loki instance |
| runLogs.lokiConfig.keepLabels | string | `nil` | List format. |
| runLogs.lokiConfig.labelsQuery | string | `nil` | LogQL labels query (without the {} as those are provided by the system) |
Expand Down
4 changes: 2 additions & 2 deletions backend/charts/api/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -204,8 +204,8 @@ kubernetes:

# If runLogs are disabled, will fallback on the kubernetes configuration above for backwards compat
runLogs:
# -- Independently set so that configuration can exist but logs can still be independently disabled. Defaults to true with k8s-pods configuration for backwards compat and because this is a helm chart this is defacto kubernetes
enabled: true
# -- Enable this if planning to surface logs within Neosync API and UI (requires a valid license).
enabled: false
# -- Possible values: k8s-pods, loki
type: k8s-pods

Expand Down
Loading

0 comments on commit f0f4e54

Please sign in to comment.