Skip to content

Include gzipped version of assets in console tarball#1031

Merged
david-crespo merged 4 commits into
mainfrom
gzip-assets
Jul 5, 2022
Merged

Include gzipped version of assets in console tarball#1031
david-crespo merged 4 commits into
mainfrom
gzip-assets

Conversation

@david-crespo

@david-crespo david-crespo commented Jul 5, 2022

Copy link
Copy Markdown
Collaborator

Console side of oxidecomputer/omicron#1345. I tried it locally, but need to change the workflow file to run on this PR (instead of only main) to confirm that it works in a GH action.

The serve-from-nexus.md changes aren't really relevant to the change, I had just been meaning to do it and used the instructions when testing locally.

I'm only gzipping .js, .map, and .css files. According to this, unlike other font file types, woff are already compressed so you should not compress them.

@vercel

vercel Bot commented Jul 5, 2022

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
console-ui-storybook ✅ Ready (Inspect) Visit Preview Jul 5, 2022 at 3:19PM (UTC)

- name: Build for Nexus
run: SHA=${{ github.sha }} yarn build-for-nexus
- name: Gzip individual files (keep originals)
run: ls dist/assets/*.{js,css,map} | xargs gzip --keep

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I love xargs

- name: Copy files to main.*
run: |
cp releases/console/${{ github.sha }}.tar.gz releases/console/main.tar.gz
cp releases/console/${{ github.sha }}.sha256.txt releases/console/main.sha256.txt

@david-crespo david-crespo Jul 5, 2022

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

99% sure nobody was using this, for reasons indicated by the changes to serve-from-nexus.md — ./tools/install_prerequisites.sh in Omicron handles the whole thing for you and it points to a commit.

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.

1 participant