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

WEBUI-1377: integrate-veracode in github action #2210

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
cf31789
WEBUI-1377: integrate-veracode in github action
rakeshkumar1019 Mar 13, 2024
9be84e7
add .npmrc
rakeshkumar1019 Mar 14, 2024
d9ff737
add .npmrc
rakeshkumar1019 Mar 14, 2024
8c43267
add .npmrc
rakeshkumar1019 Mar 14, 2024
cd352b4
add .npmrc
rakeshkumar1019 Mar 14, 2024
507a421
add .npmrc
rakeshkumar1019 Mar 14, 2024
b120de0
ls -al
rakeshkumar1019 Mar 14, 2024
f7e1cb4
disable other checks
rakeshkumar1019 Mar 14, 2024
fb82fef
update node to v3
rakeshkumar1019 Mar 15, 2024
a68bdf4
run on self hosted
rakeshkumar1019 Mar 15, 2024
582d76e
update node to v3
rakeshkumar1019 Mar 15, 2024
952d64a
set registry
rakeshkumar1019 Mar 15, 2024
f891ce0
self hosted
rakeshkumar1019 Mar 15, 2024
1731aa4
add .npmrc
rakeshkumar1019 Mar 15, 2024
165bca9
os info
rakeshkumar1019 Mar 15, 2024
cba193a
install docker
rakeshkumar1019 Mar 15, 2024
bfebef7
install docker
rakeshkumar1019 Mar 15, 2024
0d0c58b
install docker
rakeshkumar1019 Mar 15, 2024
a43fcc3
install zip
rakeshkumar1019 Mar 15, 2024
282bfac
install zip
rakeshkumar1019 Mar 15, 2024
c8ffdda
upload scan
rakeshkumar1019 Mar 15, 2024
7bdeae0
ubuntu
rakeshkumar1019 Mar 15, 2024
2f74af4
ubuntu
rakeshkumar1019 Mar 15, 2024
473e124
ubuntu
rakeshkumar1019 Mar 15, 2024
ca543ad
two yml
rakeshkumar1019 Mar 18, 2024
760f67f
two yml
rakeshkumar1019 Mar 18, 2024
91c8714
split vercode
rakeshkumar1019 Mar 18, 2024
bb75155
split vercode
rakeshkumar1019 Mar 18, 2024
ae4b347
split vercode
rakeshkumar1019 Mar 18, 2024
ba7a0dc
latest tag
rakeshkumar1019 Mar 18, 2024
c506347
latest tag rc
rakeshkumar1019 Mar 18, 2024
41fe156
latest tag rc
rakeshkumar1019 Mar 18, 2024
f69f70b
build with maintaince branch
rakeshkumar1019 Mar 18, 2024
8f31f4f
snapshot issue
rakeshkumar1019 Mar 18, 2024
45f7b15
snapshot test cuurent branch
rakeshkumar1019 Mar 18, 2024
964bcde
3.0.31-rc.0
rakeshkumar1019 Mar 18, 2024
3527cbe
workflow_dispatch:
rakeshkumar1019 Mar 18, 2024
54b05bd
two in one
rakeshkumar1019 Mar 18, 2024
b369876
two in one
rakeshkumar1019 Mar 18, 2024
9b3f15a
two in one
rakeshkumar1019 Mar 18, 2024
925806d
filepath
rakeshkumar1019 Mar 18, 2024
07a07b9
filepath
rakeshkumar1019 Mar 18, 2024
4411949
delete artifacts
rakeshkumar1019 Mar 18, 2024
ac137b2
criticality:high
rakeshkumar1019 Mar 18, 2024
b147005
criticality:high
rakeshkumar1019 Mar 18, 2024
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
79 changes: 0 additions & 79 deletions .github/workflows/a11y.yaml
Original file line number Diff line number Diff line change
@@ -1,79 +0,0 @@
name: A11y

on:
pull_request:
branches:
- maintenance-3.0.x
workflow_call:
inputs:
branch:
description: 'The current branch'
default: maintenance-3.0.x
type: string
required: false
secrets:
NPM_PACKAGES_TOKEN:
description: 'NPM_PACKAGES_TOKEN'
required: true
PACKAGES_AUTH_USER:
description: 'PACKAGES_AUTH_USER'
required: true
PACKAGES_AUTH_TOKEN:
description: 'PACKAGES_AUTH_TOKEN'
required: true

env:
REFERENCE_BRANCH: maintenance-3.0.x
NPM_REPOSITORY: https://packages.nuxeo.com/repository/npm-public/
BRANCH_NAME: ${{ github.head_ref || inputs.branch || 'maintenance-3.0.x' }}

jobs:
a11y:
runs-on: [self-hosted, master]
steps:
- uses: actions/checkout@v2
with:
ref: ${{ env.BRANCH_NAME }}

- run: git config user.name "nuxeo-webui-jx-bot" && git config user.email "[email protected]"

- uses: actions/setup-node@v3
with:
registry-url: ${{ env.NPM_REPOSITORY }}
node-version: 18
scope: '@nuxeo'

- name: Install Web UI
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PACKAGES_TOKEN }}
run: |
npm install
pushd packages/nuxeo-web-ui-ftest
npm install
popd
pushd packages/nuxeo-designer-catalog
npm install
popd

- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '11'

- name: 'Update settings.xml with server configuration'
run: |
echo '<settings>
<servers>
<server>
<id>maven-internal</id>
<username>${{ secrets.PACKAGES_AUTH_USER }}</username>
<password>${{ secrets.PACKAGES_AUTH_TOKEN }}</password>
</server>
</servers>
</settings>' > ~/.m2/settings.xml

- name: Web UI build
run: mvn -B -ntp install

- name: A11y checks
run: mvn -B -ntp -f plugin/a11y install
155 changes: 0 additions & 155 deletions .github/workflows/catalog.yaml
Original file line number Diff line number Diff line change
@@ -1,155 +0,0 @@
# This workflow generates a new version of the catalog used by Nuxeo Studio Designer.
# Note: some Catalog dependencies require Node 10.x to work.
name: Designer Catalog Generator

on:
workflow_dispatch:
inputs:
target_platform:
description: 'The Nuxeo server target platform to build the catalog for.'
default: '11.3'
required: true
branch_name:
description: 'The name of the Nuxeo Web UI branch to generate the catalog for.'
default: 'maintenance-3.0.x'
required: true
classifier:
description: 'Classifier to name a custom version of the catalog (used for testing purposes).'
default: ''
required: false

release:
types: [published]

env:
ARTIFACT_ID: view-designer-catalog
GROUP_ID: org.nuxeo.web.ui.studio

jobs:
catalog:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- run: git config --global user.name "nuxeo-webui-jx-bot" && git config --global user.email "[email protected]"

- uses: actions/setup-node@v3
with:
node-version: 14

- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'

- name: 'Update settings.xml with server configuration'
run: |
echo '<settings>
<mirrors>
<mirror>
<id>maven-internal</id>
<mirrorOf>external:*</mirrorOf>
<url>https://packages.nuxeo.com/repository/maven-internal/</url>
</mirror>
</mirrors>
<servers>
<server>
<id>nos-team</id>
<username>nuxeo-webui-jx-bot</username>
<password>${{ secrets.WEBUI_JX_BOT_GITHUB_ACTIONS_TOKEN }}</password>
</server>
<server>
<id>maven-internal</id>
<username>${{ secrets.PACKAGES_AUTH_USER }}</username>
<password>${{ secrets.PACKAGES_AUTH_TOKEN }}</password>
</server>
<server>
<id>maven-public-releases</id>
<username>${{ secrets.PACKAGES_AUTH_USER }}</username>
<password>${{ secrets.PACKAGES_AUTH_TOKEN }}</password>
</server>
<server>
<id>maven-public-snapshots</id>
<username>${{ secrets.PACKAGES_AUTH_USER }}</username>
<password>${{ secrets.PACKAGES_AUTH_TOKEN }}</password>
</server>
</servers>
</settings>' > ~/.m2/settings.xml

- name: Install libxml2-utils (xmllint)
run: sudo apt-get update && sudo apt-get install -y libxml2-utils

- name: Setup parameters (release)
if: github.event_name == 'release'
working-directory: packages/nuxeo-designer-catalog
run: |
echo "BRANCH_NAME=v${GITHUB_HEAD_REF##*/}" >> $GITHUB_ENV
echo "TARGET_PLATFORM=11.3" >> $GITHUB_ENV

- name: Setup parameters (workflow_dispatch)
if: github.event_name == 'workflow_dispatch'
run: |
echo "BRANCH_NAME=${{ github.event.inputs.branch_name }}" >> $GITHUB_ENV
echo "TARGET_PLATFORM=${{ github.event.inputs.target_platform }}" >> $GITHUB_ENV

- name: Install dependencies
working-directory: packages/nuxeo-designer-catalog
run: |
npm install
npm install -g gulp

- name: Generate catalog
working-directory: packages/nuxeo-designer-catalog
run: |
gulp catalog --tp $TARGET_PLATFORM --webui-branch $BRANCH_NAME
gulp hints --tp $TARGET_PLATFORM

- name: Bundle the catalog
run: |
sudo chmod +r pom.xml
CATALOG_VERSION=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='version']/text()" pom.xml)${{ github.event.inputs.classifier }}
pushd packages/nuxeo-designer-catalog/data/applications/nuxeo/${{ env.TARGET_PLATFORM }}
echo "CATALOG_VERSION=$CATALOG_VERSION" >> $GITHUB_ENV
CATALOG_NAME=$ARTIFACT_ID-$CATALOG_VERSION.zip
echo "CATALOG_NAME=$CATALOG_NAME" >> $GITHUB_ENV
zip -q -r $CATALOG_NAME nuxeo-web-ui data hints catalog.json
popd

- name: Archive catalog
uses: actions/upload-artifact@v3
with:
name: catalog
path: packages/nuxeo-designer-catalog/data/applications/nuxeo/${{ env.TARGET_PLATFORM }}/${{ env.CATALOG_NAME }}

- name: Upload catalog
working-directory: packages/nuxeo-designer-catalog
run: |
MVN_REPO_ID=maven-public-releases
MVN_REPO_URL=https://packages.nuxeo.com/repository/maven-public-releases/
if [[ $CATALOG_VERSION == *-SNAPSHOT ]]; then
MVN_REPO_ID=maven-public-snapshots
MVN_REPO_URL=https://packages.nuxeo.com/repository/maven-public-snapshots/
fi

pushd data/applications/nuxeo/$TARGET_PLATFORM
mvn deploy:deploy-file -Dfile=$CATALOG_NAME -DgroupId=$GROUP_ID -DartifactId=$ARTIFACT_ID -Dversion=$CATALOG_VERSION -Dpackaging=zip -DrepositoryId=$MVN_REPO_ID -Durl=$MVN_REPO_URL
popd

- name: Checkout NOS repository
uses: actions/checkout@v3
with:
repository: nuxeo/nos
token: ${{ secrets.WEBUI_JX_BOT_GITHUB_ACTIONS_TOKEN }}
path: nos

- name: Create pull request for catalog update in NOS
working-directory: nos
env:
GH_TOKEN: ${{ secrets.WEBUI_JX_BOT_GITHUB_ACTIONS_TOKEN }}
run: |
git checkout -b designer-catalog-update-$CATALOG_VERSION
mvn versions:set-property -Dproperty=view.designer.catalog.11.3 -DnewVersion=$CATALOG_VERSION
git add .
git commit -m "Update Designer catalog with version $CATALOG_VERSION"
git push origin designer-catalog-update-$CATALOG_VERSION
gh pr create --base master --fill
Loading
Loading