From d0a05a0f3f0e3c8a549d28475a78735a73f809b7 Mon Sep 17 00:00:00 2001 From: Martin Hradil Date: Mon, 10 Jun 2024 16:04:02 +0000 Subject: [PATCH] remove unused gateway config Closes #5031 --- .github/workflows/dev-gateway-release.yml | 62 ------------------- README.md | 5 +- .../standalone.gateway.prod.webpack.config.js | 11 ---- package.json | 1 - 4 files changed, 2 insertions(+), 77 deletions(-) delete mode 100644 .github/workflows/dev-gateway-release.yml delete mode 100644 config/standalone.gateway.prod.webpack.config.js diff --git a/.github/workflows/dev-gateway-release.yml b/.github/workflows/dev-gateway-release.yml deleted file mode 100644 index bf4130ad45..0000000000 --- a/.github/workflows/dev-gateway-release.yml +++ /dev/null @@ -1,62 +0,0 @@ -# Updates the "dev" github release whenever new changes are merged into master. -# This provides an up to date tarball that https://github.com/ansible/galaxy_ng can use. -name: "Dev Gateway release" - -on: - workflow_dispatch: # allow running manually - push: - branches: [ 'master' ] - -concurrency: - group: dev-gateway-release-${{ github.ref }} - cancel-in-progress: true - -jobs: - dev: - runs-on: ubuntu-latest - env: - BRANCH: 'master' # for webpack - NODE_OPTIONS: "--max-old-space-size=4096 --max_old_space_size=4096" - - steps: - - - name: "Checkout ansible-hub-ui (${{ github.ref }})" - uses: actions/checkout@v4 - - - name: "Install node 18" - uses: actions/setup-node@v4 - with: - node-version: '18' - - - name: "Update the dev tag" - run: | - git config --local user.name "Dev release workflow" - git config --local user.email "ansible-hub-ui+dev@example.com" - git tag -f dev-gateway - git push -f --tags - - - name: "Cache ~/.npm" - uses: actions/cache@v4 - with: - path: ~/.npm - key: ${{ runner.os }}-node-${{ env.GITHUB_REF }}-${{ hashFiles('**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node-${{ env.GITHUB_REF }}- - ${{ runner.os }}-node- - - - name: "Build a tarball" - run: | - npm ci || npm install - npm run build-standalone-gateway - tar -C dist/ -czvf automation-hub-ui-gateway-dist.tar.gz . - - - name: "Release" - run: | - gh release create -p "$RELEASE_TAG" --title "$RELEASE_NAME" --notes "$RELEASE_BODY" || true # may already exist - gh release upload "$RELEASE_TAG" "$RELEASE_FILE" --clobber - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - RELEASE_NAME: "UI Dev Gateway Release" - RELEASE_BODY: "Provides an up to date build off of the latest changes in the `master` branch. The `automation-hub-ui-gateway-dist.tar.gz` artifact provided here corresponds to the latest version of `master`." - RELEASE_FILE: 'automation-hub-ui-gateway-dist.tar.gz' - RELEASE_TAG: 'dev-gateway' diff --git a/README.md b/README.md index 89e6122b56..cee71a8213 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ This app can be developed in standalone, community, or insights mode. Insights m #### Modes -* `start-standalone`: assumes `oci/standalone`, http://localhost:8002/ui/ and http://localhost:55001/api/galaxy/ +* `start-standalone`: assumes `oci/standalone` or `oci/dab`, http://localhost:8002/ui/ and http://localhost:55001/api/galaxy/ * `start-community`: assumes `oci/community`, http://localhost:8002/ui/ and http://localhost:5001/api/ * `start-insights`: assumes `oci/insights`, http://localhost:8002/preview/ansible/automation-hub/ and http://localhost:55001/api/automation-hub/ * **NOTE:** This option is only relevant to Red Hat employees. @@ -95,14 +95,13 @@ List of all workflows: - `backported-labels`: Add a backported-* label when a PR is backported to stable-*; on patchback merges - `cypress`: Run Cypress integration tests; on PRs, pushes and cron - `dev-release`: Build and upload to github releases, update `dev` tag; when master is updated -- `dev-gateway-release`: Build and upload to github releases, update `dev-gateway` tag; when master is updated - `i18n`: Extract and merge l10n strings; cron - `pr-checks`: Check for linter errors, obsolete package-lock.json and merge commits; on PRs only - `stable-release`: Build and upload to github releases; when a stable release is created List by branches: -- `master`: `backported-labels`, `cypress`, `dev-release`, `dev-gateway-release`, `i18n`, `pr-checks`, `stable-release` +- `master`: `backported-labels`, `cypress`, `dev-release`, `i18n`, `pr-checks`, `stable-release` - `stable-*`: `backported-labels`, `cypress`, `i18n` (via cron from master), `pr-checks`, `stable-release` diff --git a/config/standalone.gateway.prod.webpack.config.js b/config/standalone.gateway.prod.webpack.config.js deleted file mode 100644 index 28011be71d..0000000000 --- a/config/standalone.gateway.prod.webpack.config.js +++ /dev/null @@ -1,11 +0,0 @@ -const webpackBase = require('./webpack.base.config'); - -// Compile configuration for stnadalone mode -module.exports = webpackBase({ - API_BASE_PATH: '/api/galaxy/', - UI_BASE_PATH: '/hub/', - UI_USE_HTTPS: false, - UI_DEBUG: false, - UI_EXTERNAL_LOGIN_URI: '/', - WEBPACK_PUBLIC_PATH: '/hub/', -}); diff --git a/package.json b/package.json index bd1680222f..58d7b66af6 100644 --- a/package.json +++ b/package.json @@ -74,7 +74,6 @@ "build-community": "NODE_ENV=production webpack --config config/community.prod.webpack.config.js", "build-insights": "NODE_ENV=production webpack --config config/insights.prod.webpack.config.js", "build-standalone": "NODE_ENV=production webpack --config config/standalone.prod.webpack.config.js", - "build-standalone-gateway": "NODE_ENV=production webpack --config config/standalone.gateway.prod.webpack.config.js", "eslint": "eslint src/ config/ test/", "eslint:fix": "eslint --fix src/ config/ test/", "find-unused-exports": "npx find-unused-exports --module-glob 'src/**/*.{js,ts,jsx,tsx}' --resolve-file-extensions 'tsx,ts,jsx,js' --resolve-index-files",