run full #84
This file contains hidden or 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: "Multi build" | |
| on: push | |
| #env: | |
| # JFROG_CLI_BUILD_NAME: "custom build name" | |
| # JFROG_CLI_BUILD_NUMBER: "123" | |
| env: | |
| DOCKER_REPO: docker-local | |
| IMAGE_NAME: swampapp | |
| JF_URL: https://${{ vars.JF_URL_ECO_DOCKER }}/ | |
| JFROG_CLI_LOG_LEVEL: DEBUG | |
| DOCKER_BUILD_SUMMARY: false | |
| DOCKER_BUILD_RECORD_UPLOAD: false | |
| permissions: | |
| # This is required for requesting the OIDC token | |
| id-token: write | |
| # This is required for actions/checkout | |
| contents: read | |
| security-events: write | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup JFrog CLI | |
| #uses: jfrog/setup-jfrog-cli@master | |
| uses: RobiNino/setup-jfrog-cli@fix-connection-check | |
| id: setup-cli | |
| #uses: jfrog/setup-jfrog-cli@master | |
| #uses: RobiNino/setup-jfrog-cli@reorder-summary | |
| env: | |
| #JFROG_CLI_BUILD_NAME: "custom build name" | |
| #JFROG_CLI_BUILD_NUMBER: "123" | |
| JF_URL: ${{ vars.JF_URL_ECO }} | |
| JF_USER: ${{ secrets.JF_USER }} | |
| JF_PASSWORD: ${{ secrets.JF_PASSWORD }} | |
| JF_GIT_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| #JF_PROJECT: "robip" | |
| #JF_ACCESS_TOKEN: ${{ secrets.JF_ACCESS_TOKEN }} | |
| with: | |
| #download-repository: generic-local-robi | |
| #disable-job-summary: true | |
| version: 2.67.0 | |
| # # OIDC provider name from the OIDC integration page in the JFrog Platform | |
| # #oidc-provider-name: robi-oidc-test-groups | |
| - name: Setup Python3 | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.11.5" | |
| - name: Setup Pipenv | |
| run: python -m pip install --upgrade pip setuptools wheel | |
| - name: Install npm | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "16" | |
| - name: Package managers versions | |
| run: | | |
| #jf rt dl generic-local-robi/cli-for-summary/jfrog-cli-linux-amd64/jfrog --flat --fail-no-op | |
| #chmod +x ./jfrog | |
| jf -v | |
| which jf | |
| docker --version | |
| mvn -v | |
| python --version | |
| pip --version | |
| wheel version | |
| pip show setuptools | |
| echo $VIRTUAL_ENV | |
| node -v | |
| npm -v | |
| go version | |
| - name: Docker multi platform build | |
| run: | | |
| cd docker-oci-examples/fat-manifest-example | |
| echo ${{ secrets.JF_PASSWORD }} | docker login ${{ vars.JF_URL_ECO }} -u ${{ secrets.JF_USER }} --password-stdin | |
| docker buildx install | |
| docker buildx create --use --name mybuilder --driver docker-container | |
| docker buildx build --platform=linux/amd64,linux/arm64,linux/arm/v7 --tag=ecosysjfrog.jfrog.io/docker-local/multiarch-image:1 -f=Dockerfile.Fatmanifest --metadata-file=build-metadata --push . | |
| jf rt build-docker-create docker-local --image-file build-metadata | |
| docker buildx uninstall | |
| #jf docker scan ecosysjfrog.jfrog.io/docker-local/multiarch-image:1 | |
| - name: Docker push | |
| run: | | |
| cd docker-oci-examples/docker-example | |
| export DOCKER_IMAGE_NAME=ecosysjfrog.jfrog.io/docker-local/hello-frog:1.0.0 | |
| docker build -t $DOCKER_IMAGE_NAME . | |
| jf docker push $DOCKER_IMAGE_NAME | |
| - name: Docker pull | |
| run: | | |
| jf docker pull ${{ vars.JF_URL_ECO_DOCKER }}/docker-virtual/alpine:latest | |
| - name: Docker scan | |
| run: | | |
| jf docker pull ${{ vars.JF_URL_ECO_DOCKER }}/${{ env.DOCKER_REPO }}/${{ env.IMAGE_NAME }} | |
| jf docker scan ${{ vars.JF_URL_ECO_DOCKER }}/${{ env.DOCKER_REPO }}/${{ env.IMAGE_NAME }}:latest --vuln --project=${{ vars.JF_PROJECT }} --fail=false --watches=jobsummary | |
| - name: JF Scan | |
| run: | | |
| jf scan ./curation-project/ | |
| - name: Maven build | |
| run: | | |
| cd maven-examples/maven-example | |
| jf mvnc --repo-deploy-releases=libs-release --repo-deploy-snapshots=libs-snapshot --repo-resolve-releases=libs-release --repo-resolve-snapshots=libs-snapshot | |
| jf mvn clean install | |
| - name: Pip build | |
| run: | | |
| cd python-example/pip-example/ | |
| jf pip-config --repo-resolve=robi-pypi-virtual | |
| jf pip install . --module=jfrog-python-example | |
| python setup.py sdist bdist_wheel | |
| jf rt u dist/ robi-pypi-virtual/ --module=jfrog-python-example | |
| # | |
| - name: Npm build | |
| run: | | |
| cd npm-example | |
| jf npm-config --repo-resolve=robi-npm --repo-deploy=robi-npm | |
| jf npm i | |
| jf npm publish | |
| # | |
| - name: Go build | |
| run: | | |
| cd golang-example | |
| jf go-config --repo-resolve=go --repo-deploy=go | |
| jf go build | |
| jf go-publish v1.0.0 | |
| # | |
| - name: Generic build | |
| run: | | |
| cd bash-example | |
| jf rt u ./deploy-file.sh generic-local/ --module=my-generic-module | |
| jf rt dl generic-local/deploy-file.sh ./dependency-file --module=my-generic-module | |
| # | |
| - name: Generic build project | |
| run: | | |
| cd bash-example | |
| jf rt u ./deploy-file.sh robip-generic-local/ --module=my-generic-module-project | |
| # | |
| - name: Terraform build | |
| run: | | |
| cd terraformproject | |
| jf terraform-config --repo-deploy=robi-terraform-local | |
| cd aws | |
| jf terraform publish --namespace=example --provider=aws --tag=v0.0.1 --module=terraform-module --exclusions="*test*;*ignore*" | |
| - name: Publish build info | |
| run: | | |
| jf rt bce | |
| jf rt bp | |
| #jf build-scan --vuln |