Skip to content

Commit

Permalink
Prepare for Netbox 4.2
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasge committed Jan 7, 2025
1 parent 69e997f commit 1a70f97
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 26 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
- ./build-latest.sh
- PRERELEASE=true ./build-latest.sh
- ./build.sh feature
- ./build.sh develop
- ./build.sh main
os:
- ubuntu-latest
- self-hosted
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- ./build-latest.sh
- PRERELEASE=true ./build-latest.sh
- ./build.sh feature
- ./build.sh develop
- ./build.sh main
platform:
- linux/amd64,linux/arm64
fail-fast: false
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ RUN export DEBIAN_FRONTEND=noninteractive \
&& apt-get update -qq \
&& apt-get install \
--yes -qq --no-install-recommends \
unit=1.33.0-1~noble \
unit-python3.12=1.33.0-1~noble \
unit=1.34.0-1~noble \
unit-python3.12=1.34.0-1~noble \
&& rm -rf /var/lib/apt/lists/*

COPY --from=builder /opt/netbox/venv /opt/netbox/venv
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.0.2
3.1.0
33 changes: 13 additions & 20 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,8 @@ SKIP_GIT If defined, git is not invoked and \${NETBOX_PATH} will not be alter
TAG The version part of the image tag.
${_GREEN}Default:${_CLEAR}
When <branch>=master: latest
When <branch>=develop: snapshot
Else: same as <branch>
When <branch>=main: snapshot
Else: same as <branch>
IMAGE_NAMES The names used for the image including the registry
Used for tagging the image.
Expand Down Expand Up @@ -104,24 +103,21 @@ GH_ACTION If defined, special 'echo' statements are enabled that set the
${_GREEN}Default:${_CLEAR} undefined
CHECK_ONLY Only checks if the build is needed and sets the GH Action output.
${_GREEN}Default:${_CLEAR} undefined
${_BOLD}Examples:${_CLEAR}
${0} master
This will fetch the latest 'master' branch, build a Docker Image and tag it
'netboxcommunity/netbox:latest'.
${0} develop
This will fetch the latest 'develop' branch, build a Docker Image and tag it
${0} main
This will fetch the latest 'main' branch, build a Docker Image and tag it
'netboxcommunity/netbox:snapshot'.
${0} v2.6.6
This will fetch the 'v2.6.6' tag, build a Docker Image and tag it
'netboxcommunity/netbox:v2.6.6' and 'netboxcommunity/netbox:v2.6'.
${0} v4.2.0
This will fetch the 'v4.2.0' tag, build a Docker Image and tag it
'netboxcommunity/netbox:v4.2.0' and 'netboxcommunity/netbox:v4.2'.
${0} develop-2.7
This will fetch the 'develop-2.7' branch, build a Docker Image and tag it
'netboxcommunity/netbox:develop-2.7'.
${0} feature
This will fetch the 'feature' branch, build a Docker Image and tag it
'netboxcommunity/netbox:feature'.
SRC_ORG=cimnine ${0} feature-x
This will fetch the 'feature-x' branch from https://github.com/cimnine/netbox.git,
Expand Down Expand Up @@ -259,10 +255,7 @@ DOCKER_REGISTRY="${DOCKER_REGISTRY-docker.io}"
DOCKER_ORG="${DOCKER_ORG-netboxcommunity}"
DOCKER_REPO="${DOCKER_REPO-netbox}"
case "${NETBOX_BRANCH}" in
master)
TAG="${TAG-latest}"
;;
develop)
main)
TAG="${TAG-snapshot}"
;;
*)
Expand All @@ -278,7 +271,7 @@ TARGET_DOCKER_TAG_PROJECT="${TARGET_DOCKER_TAG}-${PROJECT_VERSION}"

###
# composing the additional DOCKER_SHORT_TAG,
# i.e. "v2.6.1" becomes "v2.6",
# i.e. "v4.2.0" becomes "v4.2",
# which is only relevant for version tags
# Also let "latest" follow the highest version
###
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
netbox: &netbox
image: docker.io/netboxcommunity/netbox:${VERSION-v4.1-3.0.2}
image: docker.io/netboxcommunity/netbox:${VERSION-v4.2-3.1.0}
depends_on:
- postgres
- redis
Expand Down

0 comments on commit 1a70f97

Please sign in to comment.