Merge pull request #1806 from Khuddusshariff0022/1.1.5.5_MOSIP_30470_… #3057
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Maven Package upon a push | |
on: | |
pull_request: | |
types: [closed] | |
push: | |
branches: | |
- master | |
- 1.* | |
- develop | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v1 | |
with: | |
ref: ${{ github.ref }} | |
java-version: 11 | |
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml | |
settings-path: ${{ github.workspace }} # location for the settings.xml file | |
- name: Setup branch and env | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
echo "GPG_TTY=$(tty)" >> $GITHUB_ENV | |
- name: Setup branch and GPG public key | |
run: | | |
# Strip git ref prefix from version | |
echo ${{ env.BRANCH_NAME }} | |
echo ${{ env.GPG_TTY }} | |
sudo apt-get --yes install gnupg2 | |
gpg2 --import ./.github/keys/mosipgpgkey_pub.gpg | |
gpg2 --quiet --batch --passphrase=${{secrets.gpg_secret}} --allow-secret-key-import --import ./.github/keys/mosipgpgkey_sec.gpg | |
- uses: actions/cache@v1 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven-${{ env.BRANCH_NAME }} | |
- name: Setup the settings file for ossrh server | |
run: echo "<settings> <servers> <server> <id>ossrh</id> <username>${{secrets.ossrh_user}}</username> <password>${{secrets.ossrh_secret}}</password> </server> </servers> <profiles> <profile> <id>ossrh</id> <activation> <activeByDefault>true</activeByDefault> </activation> <properties> <gpg.executable>gpg2</gpg.executable> <gpg.passphrase>${{secrets.gpg_secret}}</gpg.passphrase> </properties> </profile> <profile> <id>allow-snapshots</id> <activation><activeByDefault>true</activeByDefault></activation> <repositories> <repository> <id>snapshots-repo</id> <url>https://oss.sonatype.org/content/repositories/snapshots</url> <releases><enabled>false</enabled></releases> <snapshots><enabled>true</enabled></snapshots> </repository> <repository> <id>releases-repo</id> <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url> <releases><enabled>true</enabled></releases> <snapshots><enabled>false</enabled></snapshots> </repository> </repositories> </profile> <profile> <id>sonar</id> <properties> <sonar.sources>.</sonar.sources> <sonar.host.url>https://sonarcloud.io</sonar.host.url> </properties> <activation> <activeByDefault>false</activeByDefault> </activation> </profile> </profiles> </settings>" > $GITHUB_WORKSPACE/settings.xml | |
- name: Build with Maven | |
run: | | |
cd registration-processor | |
mvn -B package -s $GITHUB_WORKSPACE/settings.xml --file pom.xml | |
- name: Ready the springboot artifacts | |
run: find -name '*.jar' -executable -type f -exec zip release.zip {} + | |
- name: Upload the springboot jars | |
uses: actions/upload-artifact@v1 | |
with: | |
name: release | |
path: ./release.zip | |
publish_to_nexus: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v1 | |
with: | |
ref: ${{ github.ref }} | |
java-version: 11 | |
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml | |
settings-path: ${{ github.workspace }} # location for the settings.xml file | |
- uses: actions/checkout@v2 | |
- name: Setup branch and env | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
echo "GPG_TTY=$(tty)" >> $GITHUB_ENV | |
- name: Setup branch and GPG public key | |
run: | | |
# Strip git ref prefix from version | |
echo ${{ env.BRANCH_NAME }} | |
echo ${{ env.GPG_TTY }} | |
sudo apt-get --yes install gnupg2 | |
gpg2 --import ./.github/keys/mosipgpgkey_pub.gpg | |
gpg2 --quiet --batch --passphrase=${{secrets.gpg_secret}} --allow-secret-key-import --import ./.github/keys/mosipgpgkey_sec.gpg | |
- uses: actions/cache@v1 | |
with: | |
path: ~/.m2/repository | |
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }} | |
restore-keys: | | |
${{ runner.os }}-maven-${{ env.BRANCH_NAME }} | |
- name: Install xmllint | |
run: | | |
sudo apt-get update | |
sudo apt-get install libxml2-utils | |
- name: Setup the settings file for ossrh server | |
run: echo "<settings> <servers> <server> <id>ossrh</id> <username>${{secrets.RELEASE_USER}}</username> <password>${{secrets.RELEASE_TOKEN}}</password> </server> </servers> <profiles> <profile> <id>ossrh</id> <activation> <activeByDefault>true</activeByDefault> </activation> <properties> <gpg.executable>gpg2</gpg.executable> <gpg.passphrase>${{secrets.gpg_secret}}</gpg.passphrase> </properties> </profile> <profile> <id>allow-snapshots</id> <activation><activeByDefault>true</activeByDefault></activation> <repositories> <repository> <id>snapshots-repo</id> <url>https://oss.sonatype.org/content/repositories/snapshots</url> <releases><enabled>false</enabled></releases> <snapshots><enabled>true</enabled></snapshots> </repository> <repository> <id>releases-repo</id> <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url> <releases><enabled>true</enabled></releases> <snapshots><enabled>false</enabled></snapshots> </repository> </repositories> </profile> <profile> <id>sonar</id> <properties> <sonar.sources>.</sonar.sources> <sonar.host.url>https://sonarcloud.io</sonar.host.url> </properties> <activation> <activeByDefault>false</activeByDefault> </activation> </profile> </profiles> </settings>" > $GITHUB_WORKSPACE/settings.xml | |
- name: Publish the maven package | |
run: | | |
mvn deploy -DaltDeploymentRepository=ossrh::default::${{ secrets.RELEASE_URL }} -s $GITHUB_WORKSPACE/settings.xml -f pom.xml | |
env: | |
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }} | |
GPG_TTY: $(tty) | |
- name: Analyze with SonarCloud | |
run: | | |
cd registration-processor | |
mvn clean -B verify sonar:sonar -Dsonar.projectKey=${{ secrets.PROJECT_KEY }} -Dsonar.organization=${{ secrets.ORG_KEY }} -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=${{ secrets.SONAR_TOKEN }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
registration-processor-common-camel-bridge: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-common-camel-bridge | |
SERVICE_LOCATION: registration-processor/registration-processor-common-camel-bridge | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Get current date | |
id: date | |
run: echo "::set-output name=date::$(date +'%Y-%m-%d')" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --build-arg SOURCE=mosip --build-arg COMMIT_HASH=$(git rev-parse HEAD) --build-arg COMMIT_ID=$(git rev-parse --short HEAD) --build-arg BUILD_TIME=${{steps.date.outputs.date}} --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
if [[ $BRANCH_NAME == master ]]; then | |
VERSION=latest | |
else | |
VERSION=$BRANCH_NAME | |
fi | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-osi-validator-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-osi-validator-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-osi-validator-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the registration-processor-osi-validator-stage | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-securezone-notification-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-securezone-notification-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-securezone-notification-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the registration-processor-securezone-notification-stage | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-external-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-external-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-external-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the registration-processor-external-stage | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-packet-validator-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-packet-validator-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-packet-validator-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-packet-uploader-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-packet-uploader-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-packet-uploader-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-quality-checker-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-quality-checker-stage | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-quality-checker-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-external-integration-service: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-external-integration-service | |
SERVICE_LOCATION: registration-processor/pre-processor/registration-processor-external-integration-service | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-printing-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-printing-stage | |
SERVICE_LOCATION: registration-processor/post-processor/registration-processor-printing-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-registration-transaction-service: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-registration-transaction-service | |
SERVICE_LOCATION: registration-processor/post-processor/registration-processor-registration-transaction-service | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-message-sender-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-message-sender-stage | |
SERVICE_LOCATION: registration-processor/post-processor/registration-processor-message-sender-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-manual-verification-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-manual-verification-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-manual-verification-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-abis-handler-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-abis-handler-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-abis-handler-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-abis-middleware-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-abis-middleware-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-abis-middleware-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-uin-generator-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-uin-generator-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-uin-generator-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-abis: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-abis | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-abis | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-bio-dedupe-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-bio-dedupe-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-bio-dedupe-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-reprocessor-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-reprocessor-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-reprocessor-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-demo-dedupe-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-demo-dedupe-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-demo-dedupe-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-biometric-authentication-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-biometric-authentication-stage | |
SERVICE_LOCATION: registration-processor/core-processor/registration-processor-biometric-authentication-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-packet-receiver-stage: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-packet-receiver-stage | |
SERVICE_LOCATION: registration-processor/init/registration-processor-packet-receiver-stage | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-dmz-packet-server: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-dmz-packet-server | |
SERVICE_LOCATION: registration-processor/init/registration-processor-dmz-packet-server | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info | |
id: getVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/version.xml | |
xpath: version | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getVersion.outputs.info}}" | |
VERSION=${{steps.getVersion.outputs.info}} | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION | |
docker-registration-processor-registration-status-service: | |
needs: build | |
runs-on: ubuntu-latest | |
env: | |
NAMESPACE: mosipdev | |
SERVICE_NAME: registration-processor-registration-status-service | |
SERVICE_LOCATION: registration-processor/init/registration-processor-registration-status-service | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/download-artifact@v1 | |
with: | |
name: release | |
path: ./ | |
- name: Setup branch name | |
run: | | |
# Strip git ref prefix from version | |
echo "BRANCH_NAME=$(echo ${{ github.ref }} | sed -e 's,.*/\(.*\),\1,')" >> $GITHUB_ENV | |
- name: Get version info from pom | |
id: getPomVersion | |
uses: mavrosxristoforos/[email protected] | |
with: | |
xml-file: ./${{ env.SERVICE_LOCATION }}/pom.xml | |
xpath: /*[local-name()="project"]/*[local-name()="version"] | |
- name: Unzip and extract the ${{ env.SERVICE_NAME }} | |
run: unzip -uj "release.zip" "${{ env.SERVICE_LOCATION }}/target/*" -d "./${{ env.SERVICE_LOCATION }}/target" | |
- name: Build image | |
run: | | |
cd "./${{env.SERVICE_LOCATION}}" | |
docker build . --file Dockerfile --tag ${{ env.SERVICE_NAME }} | |
- name: Log into registry | |
run: echo "${{ secrets.release_docker_hub }}" | docker login -u ${{ secrets.actor_docker_hub }} --password-stdin | |
- name: Push image | |
run: | | |
IMAGE_ID=$NAMESPACE/$SERVICE_NAME | |
# Change all uppercase to lowercase | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
echo "push version ${{steps.getPomVersion.outputs.info}}" | |
VERSION=$BRANCH_NAME | |
echo IMAGE_ID=$IMAGE_ID | |
echo VERSION=$VERSION | |
docker tag $SERVICE_NAME $IMAGE_ID:$VERSION | |
docker push $IMAGE_ID:$VERSION |