Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make released binary names more consistent #16667

Merged
merged 3 commits into from
Dec 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -335,10 +335,10 @@ $(SRCBINDIR)/podman$(BINSFX): $(SOURCES) go.mod go.sum | $(SRCBINDIR)
-tags "${REMOTETAGS}" \
-o $@ ./cmd/podman

$(SRCBINDIR)/podman-remote-static: $(SRCBINDIR) $(SOURCES) go.mod go.sum
$(SRCBINDIR)/podman-remote-static-linux_amd64 $(SRCBINDIR)/podman-remote-static-linux_arm64: $(SRCBINDIR)/podman-remote-static-linux_%: $(SRCBINDIR) $(SOURCES) go.mod go.sum
CGO_ENABLED=0 \
GOOS=linux \
GOARCH=$(GOARCH) \
GOARCH=$* \
$(GO) build \
$(BUILDFLAGS) \
$(GO_LDFLAGS) '$(LDFLAGS_PODMAN_STATIC)' \
Expand All @@ -362,8 +362,9 @@ $(SRCBINDIR)/quadlet: $(SOURCES) go.mod go.sum
.PHONY: quadlet
quadlet: bin/quadlet

PHONY: podman-remote-static
podman-remote-static: $(SRCBINDIR)/podman-remote-static
PHONY: podman-remote-static-linux_amd64 podman-remote-static-linux_arm64
podman-remote-static-linux_amd64: $(SRCBINDIR)/podman-remote-static-linux_amd64
podman-remote-static-linux_arm64: $(SRCBINDIR)/podman-remote-static-linux_arm64

.PHONY: podman-winpath
podman-winpath: $(SOURCES) go.mod go.sum
Expand Down
9 changes: 6 additions & 3 deletions RELEASE_PROCESS.md
Original file line number Diff line number Diff line change
Expand Up @@ -244,10 +244,12 @@ spelled with complete minutiae.
$ make podman-remote-release-darwin_amd64.zip \
podman-remote-release-darwin_arm64.zip \
podman-remote-release-windows_amd64.zip \
podman-remote-static
podman-remote-static-linux_amd64 \
podman-remote-static-linux_arm64
$ mv podman-* bin/
$ cd bin/
$ tar -cvzf podman-remote-static.tar.gz podman-remote-static
$ tar -cvzf podman-remote-static-linux_amd64.tar.gz podman-remote-static-linux_amd64
$ tar -cvzf podman-remote-static-linux_arm64.tar.gz podman-remote-static-linux_arm64
$ sha256sum *.zip *.tar.gz > shasums
```

Expand All @@ -270,7 +272,8 @@ spelled with complete minutiae.
* podman-remote-release-darwin_arm64.zip
* podman-remote-release-windows_amd64.zip
* podman-vX.Y.Z.msi
* podman-remote-static.tar.gz
* podman-remote-static-linux_amd64.tar.gz
* podman-remote-static-linux_arm64.tar.gz
* shasums
1. Click the Publish button to make the release (or pre-release)
available.
Expand Down
7 changes: 6 additions & 1 deletion contrib/pkginstaller/Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
SHELL := bash

ARCH ?= aarch64
ifeq ($(ARCH), aarch64)
GOARCH:=arm64
else
GOARCH:=$(ARCH)
endif
GVPROXY_VERSION ?= 0.4.0
QEMU_VERSION ?= 7.1.0-1
GVPROXY_RELEASE_URL ?= https://github.com/containers/gvisor-tap-vsock/releases/download/v$(GVPROXY_VERSION)/gvproxy-darwin
QEMU_RELEASE_URL ?= https://github.com/containers/podman-machine-qemu/releases/download/v$(QEMU_VERSION)/podman-machine-qemu-$(ARCH)-$(QEMU_VERSION).tar.xz
PACKAGE_DIR ?= out/packaging
TMP_DOWNLOAD ?= tmp-download
PACKAGE_ROOT ?= root
PKG_NAME := podman-installer-macos-$(ARCH).pkg
PKG_NAME := podman-installer-macos-$(GOARCH).pkg

default: pkginstaller

Expand Down
13 changes: 7 additions & 6 deletions contrib/pkginstaller/package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ arch=$(cat "${BASEDIR}/ARCH")

function build_podman() {
pushd "$1"
local goArch="${arch}"
if [ "${goArch}" = aarch64 ]; then
goArch=arm64
fi
make GOARCH="${goArch}" podman-remote HELPER_BINARIES_DIR="${HELPER_BINARIES_DIR}"
make GOARCH="${goArch}" podman-mac-helper
cp bin/darwin/podman "contrib/pkginstaller/out/packaging/${binDir}/podman"
Expand Down Expand Up @@ -66,6 +62,11 @@ function signQemu() {
--entitlements "${BASEDIR}/hvf.entitlements" "${qemuBinDir}/qemu-system-${qemuArch}"
}

goArch="${arch}"
if [ "${goArch}" = aarch64 ]; then
goArch=arm64
fi

build_podman "../../../../"
sign "${binDir}/podman"
sign "${binDir}/gvproxy"
Expand All @@ -86,7 +87,7 @@ productbuild --distribution "${BASEDIR}/Distribution" \
rm "${OUTPUT}/podman.pkg"

if [ ! "${NO_CODESIGN}" -eq "1" ]; then
productsign --timestamp --sign "${PRODUCTSIGN_IDENTITY}" "${OUTPUT}/podman-unsigned.pkg" "${OUTPUT}/podman-installer-macos-${arch}.pkg"
productsign --timestamp --sign "${PRODUCTSIGN_IDENTITY}" "${OUTPUT}/podman-unsigned.pkg" "${OUTPUT}/podman-installer-macos-${goArch}.pkg"
else
mv "${OUTPUT}/podman-unsigned.pkg" "${OUTPUT}/podman-installer-macos-${arch}.pkg"
mv "${OUTPUT}/podman-unsigned.pkg" "${OUTPUT}/podman-installer-macos-${goArch}.pkg"
fi
4 changes: 2 additions & 2 deletions contrib/podmanremoteimage/Containerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
FROM registry.access.redhat.com/ubi8/go-toolset:latest AS builder
WORKDIR /opt/app-root/src
COPY . .
RUN make podman-remote-static
RUN make podman-remote-static-linux_amd64
RUN GOOS=windows make podman-remote
RUN GOOS=darwin make podman-remote

FROM scratch
COPY --from=builder /opt/app-root/src/bin .
ENTRYPOINT ["/podman-remote-static"]
ENTRYPOINT ["/podman-remote-static-linux_amd64"]
2 changes: 1 addition & 1 deletion contrib/podmanremoteimage/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ $ podman cp $(podman create --name remote-temp quay.io/containers/podman-remote-

- For Linux binary
```bash
$ podman cp $(podman create --name remote-temp quay.io/containers/podman-remote-artifacts:latest):/podman-remote-static . && podman rm remote-temp
$ podman cp $(podman create --name remote-temp quay.io/containers/podman-remote-artifacts:latest):/podman-remote-static-linux_amd64 . && podman rm remote-temp
```

- For Mac binary
Expand Down