Skip to content

Commit 7a34e3c

Browse files
committed
docs: update local build instructions
Signed-off-by: hammadsaedi <[email protected]>
1 parent 1231c71 commit 7a34e3c

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@
33
/.*_history
44
/.viminfo
55
.vscode
6+
artifacts/

README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,17 @@ k3s-upgrade is an image that is responsible of upgrading k3s version via the [Sy
1010
To build the k3s-upgrade image locally, you can run the following:
1111

1212
```
13-
export ARCH=amd64 TAG=v1.17.2+k3s1
14-
docker build --build-arg ARCH --build-arg TAG --tag ${REPO:=k3s-io}/k3s-upgrade:${TAG/+/-} .
13+
export ARCH=amd64 TAG=v1.33.5+k3s1 VERSION=v1.33.5+k3s1
14+
make download-assets
15+
docker buildx build --platform=linux/amd64 --build-arg TAG=$TAG --build-arg ARTIFACT=k3s --tag ${REPO:=rancher}/k3s-upgrade:${TAG/+/-} .
1516
```
1617

18+
**Environment Variables:**
19+
- `ARCH`: Target architecture (amd64, arm64, arm/v7)
20+
- `TAG`: Image tag (used for Docker image naming)
21+
- `VERSION`: K3s version (used for downloading artifacts)
22+
- `REPO`: Docker repository (defaults to "rancher")
23+
1724
## Usage
1825

1926
### Prerequisites

0 commit comments

Comments
 (0)