tailwind
tailwind copied to clipboard
Fails when running in CI
mix tailwind default --minify works ok locally but seems to fail in GCP Cloud Build where the reason doesn't seem to be obvious.
deploy.yml
- name: 'gcr.io/something/docker-base-images/alpine-elixir-builder'
id: 'run tailwind'
entrypoint: mix
args: [ 'tailwind', 'default', '--minify' ]
output
17:08:26.506 [debug] Downloading tailwind from https://github.com/tailwindlabs/tailwindcss/releases/download/v3.0.3/tailwindcss-linux-x64
** (Mix) `mix tailwind default --minify` exited with 2
@abel-cherinet-liqid I run into the same issue and fixed it running apk add --no-cache gcompat. More info here.
Hope it helps! 🙂
Unfortunately not, also tried installing libc6-compat and still same error
@abel-cherinet-liqid does adding the combination of build-base and gcompat work for you?
This is going to keep coming up for alpine users - I opened a discussion to switch to static builds on tailwind's side here: https://github.com/tailwindlabs/tailwindcss/discussions/6785
@abel-cherinet-liqid does adding the combination of
build-baseandgcompatwork for you?
Thanks for this discussion! I came across this issue and tried following the suggestions, but it seems to run at odds with similar/related issues with the dart-sass library+installer:
From this issue: https://github.com/CargoSense/dart_sass/issues/13
A PR was opened that includes the following notes with their fix:
Notes: The Alpine package gcompat vs libc6-compat will not work.
Is there a way that we can satisfy both dependencies in alpine to be able to run the dart-sass and tailwindcss installers?
@fertapric @mveytsman sorry for late response, I figured later that adding gcompat worked! I was trying to install gcompat as a GCP Cloud Build step which didnt persist to the tailwind step. Now I installed gcompat in my docker file and seems to work fine this time. Thank you for the help!
I got a PR switching the build type to linuxstatic into tailwind (https://github.com/tailwindlabs/tailwindcss/pull/6914)
this will actually fix the problem (and related issues on nixos)
Can we keep this issue open until a new version is released and we can set that as the default in this package?
This should be included in Tailwind CSS 3.0.12. So I guess this can be closed now ☺️