2021-11-12 19:12:40 +02:00
|
|
|
#!/bin/bash
|
2021-11-12 19:18:46 +02:00
|
|
|
# chmod u+x build-amd64.sh
|
2021-11-12 19:12:40 +02:00
|
|
|
echo "Welcome!"
|
|
|
|
|
2022-02-19 00:09:23 +02:00
|
|
|
version="1.1.3-alpha3"
|
2021-11-12 19:12:40 +02:00
|
|
|
localRegistryPass="***REMOVED***"
|
|
|
|
|
|
|
|
echo "Create docker image with version $version."
|
|
|
|
docker image build -t "identity-server:$version" -f "IdentityServer.Api/Dockerfile" .
|
|
|
|
|
|
|
|
echo "Tag docker image with registry prefix."
|
|
|
|
docker tag identity-server:$version alpine-nexus:8500/identity/identity-server:$version
|
|
|
|
|
|
|
|
echo "Login to alpine-nexus registry."
|
|
|
|
docker login --username=admin --password=$localRegistryPass alpine-nexus:8500
|
|
|
|
|
|
|
|
echo "Push image alpine-nexus:8500/identity/identity-server:$version to registry."
|
|
|
|
docker push alpine-nexus:8500/identity/identity-server:$version
|
|
|
|
|
|
|
|
echo "Remove image alpine-nexus:8500/identity/identity-server:$version from local machine."
|
|
|
|
docker rmi alpine-nexus:8500/identity/identity-server:$version
|
|
|
|
|
|
|
|
echo "DONE!"
|