Skip to content

Commit

Permalink
feat: Add flux tool. (#250)
Browse files Browse the repository at this point in the history
* Add flux tool.

* Addressed requested changes.

Co-authored-by: Michael Kriese <[email protected]>
  • Loading branch information
danports and viceice authored Jan 21, 2022
1 parent 8ae2e22 commit 26cf7d7
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/usr/local/buildpack/tools/flux.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash

tool_path=$(find_tool_path)
if [[ -z "${tool_path}" ]]; then
INSTALL_DIR=$(get_install_dir)
base_path=${INSTALL_DIR}/${TOOL_NAME}
tool_path=${base_path}/${TOOL_VERSION}
mkdir -p ${tool_path}

ARCH=amd64
BIN_URL="https://github.com/fluxcd/flux2/releases/download/v${TOOL_VERSION}/flux_${TOOL_VERSION}_linux_${ARCH}.tar.gz"
curl -sL ${BIN_URL} -o /tmp/flux.tar.gz
tar -C ${tool_path} -zxvf /tmp/flux.tar.gz
fi

link_wrapper ${TOOL_NAME} ${tool_path}

flux -v
3 changes: 3 additions & 0 deletions test/Dockerfile.bionic
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ RUN install-tool erlang 22.3.2
# renovate: datasource=docker versioning=docker
RUN install-tool elixir 1.13.2

# renovate: datasource=github-releases lookupName=fluxcd/flux2
RUN install-tool flux v0.25.3

# renovate: datasource=docker versioning=docker
RUN install-tool golang 1.17.6

Expand Down
3 changes: 3 additions & 0 deletions test/latest/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,9 @@ ARG APT_HTTP_PROXY

ARG IGNORED_TOOLS=powershell,node

# renovate: datasource=github-releases lookupName=fluxcd/flux2
RUN install-tool flux v0.25.3

# renovate: datasource=github-releases lookupName=git-lfs/git-lfs
RUN install-tool git-lfs v3.0.2

Expand Down

0 comments on commit 26cf7d7

Please sign in to comment.