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

builder-api-proxy dependencies updated for LTS-2024 channel #1827

Merged
merged 3 commits into from
Aug 22, 2024

Conversation

agadgil-progress
Copy link
Contributor

Updated following dependencies -

  1. NodeJS to version - 18.12.1 (available on LTS-2024)
  2. builder-web dependencies - webpack, node-sass etc.
  3. Removed not required gcc, make and python2 from the plan.sh dependency

Now at-least locally builds with LTS-2024 channel and basic make and make test works locally.

Checking mileage with CI.

@agadgil-progress agadgil-progress marked this pull request as draft July 31, 2024 10:58
@agadgil-progress
Copy link
Contributor Author

@rahulgoel1 @sajjaphani : It seems there is no verify job for builder-api-proxy component. As a result the build is successful.

If you think it's worthwhile adding the job, then I can add the job for that.

.expeditor/verify.pipeline.yml Show resolved Hide resolved
# This is done because some of our `hab` packages like `hab-studio` are
# not available on `LTS-2024` yet.
- HAB_FALLBACK_CHANNEL=stable
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think the fallback channel is going to help here. stable is already the default but this variable is only used for a hab build and not installing missing hab components before entering the studio which is the case here.

I think (hope) the solution here is to leave HAB_BLDR_CHANNEL alone which will get the studio from stable. Then when it enters the studio and starts the build it will use HAB_INTERNAL_BLDR_CHANNEL to set HAB_BLDR_CHANNEL inside of the studio.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mwrock : Wondering if it's a better idea to pass HAB_STUDIO_SECRET_HAB_BLDR_CHANNEL and HAB_STUDIO_SECRET_HAB_FALLBACK_CHANNEL (both set to LTS-2024) env variables? This makes sure inside the studio accidentally stable does not get used at all?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am able to make progress in the build with the two env variables above, still seeing some issues, but don't look related to hab or studio

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh man I'm sorry. You are absolutely correct. HAB_STUDIO_SECRET_HAB_BLDR_CHANNEL was the correct variable. I'm not sure setting HAB_STUDIO_SECRET_HAB_FALLBACK_CHANNEL to stable will do anything because I think that is the default anyways.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope: I meant setting HAB_STUDIO_SECRET_HAB_FALLBACK_CHANNEL to LTS-2024 so that, we know inside studio stable is not accidentally used somehow.

@agadgil-progress agadgil-progress force-pushed the agadgil/lts-2024-node-updates branch from 3d4548c to 01064cb Compare August 12, 2024 07:06
@mwrock
Copy link
Contributor

mwrock commented Aug 12, 2024

@agadgil-progress you might consider adding export NODE_OPTIONS="--dns-result-order=ipv4first" to the build and se if that resolves the network problem with fetching from npm.

Updated following dependencies -

1. NodeJS to version - 18.12.1 (available on LTS-2024)
2. `builder-web` dependencies - `webpack`, `node-sass` etc.
3. Removed not required `gcc`, `make` and `python2` from the `plan.sh`
dependency

Now at-least locally builds with `LTS-2024` channel and basic `make` and
`make test` works locally

Signed-off-by: Abhijit Gadgil <[email protected]>
Using `stable` as a fallback channel.

Currently some of our own `hab` packages are not available on the
`LTS-2024` channel. We are using this as a fallback channel for now.

Signed-off-by: Abhijit Gadgil <[email protected]>
Using `HAB_SECRET_*` environment variables, this should make sure those
environment variables are *only* set in `studio`, how we enter `studio`
should not matter. This should help working with old versions of
`studio` that are available only on `stable` in the CI

Added `hab origin key generate habitat`

Passing Node Options to make sure we use IPv4

Setting `NODE_OPTIONS` as HAB_SECRET_... env var

Signed-off-by: Abhijit Gadgil <[email protected]>
@agadgil-progress agadgil-progress force-pushed the agadgil/lts-2024-node-updates branch from aa88b39 to d8a51a6 Compare August 14, 2024 13:17
@agadgil-progress agadgil-progress marked this pull request as ready for review August 14, 2024 13:18
@rahulgoel1
Copy link
Contributor

@agadgil-progress should we merge this PR ?

@agadgil-progress
Copy link
Contributor Author

@agadgil-progress should we merge this PR ?

Yes, I had it planned yesterday, there is one small change I have to do because LTS-2024 channel upgraded node so will need to quickly test it once before merging otherwise the build on main will fail. Will close this today.

@agadgil-progress agadgil-progress merged commit 3dbf9c1 into main Aug 22, 2024
7 checks passed
@agadgil-progress agadgil-progress deleted the agadgil/lts-2024-node-updates branch August 22, 2024 05:27
@agadgil-progress
Copy link
Contributor Author

Confirmed, this builds against LTS-2024 channel and merged.

chef-expeditor bot pushed a commit that referenced this pull request Aug 22, 2024
Obvious fix; these changes are the result of automation not creative thinking.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants