-
Notifications
You must be signed in to change notification settings - Fork 9
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
Deploy Auth to Fly.io PROD #172
Comments
Picking this up now. Dunno if I will finish today ... but let's see how far we can get. |
Trying the "Speedrun" https://fly.io/docs/speedrun/
Output:
Attempt to launch new app:
Error:
|
|
1 similar comment
|
|
flyctl deploy
==> Verifying app config
--> Verified app config
==> Building image
Remote builder fly-builder-rough-river-3816 ready
==> Creating build context
--> Creating build context done
==> Building image with Docker
--> docker host: 20.10.12 linux x86_64
[+] Building 158.9s (0/1)
[+] Building 77.3s (23/24)
=> [internal] load remote build context 0.0s
=> copy /context / 0.8s
=> [internal] load metadata for docker.io/library/alpine:3.13.3 1.1s
=> [internal] load metadata for docker.io/hexpm/elixir:1.12.1-erlang-24.0.1-alpine-3. 1.2s
=> [app 1/5] FROM docker.io/library/alpine:3.13.3@sha256:826f70e0ac33e99a72cf20fb0571 0.0s
=> [build 1/15] FROM docker.io/hexpm/elixir:1.12.1-erlang-24.0.1-alpine-3.13.3@sha25 0.0s
=> CACHED [app 2/5] RUN apk add --no-cache libstdc++ openssl ncurses-libs 0.0s
=> CACHED [app 3/5] WORKDIR /app 0.0s
=> CACHED [app 4/5] RUN chown nobody:nobody /app 0.0s
=> CACHED [build 2/15] RUN apk add --no-cache build-base npm 0.0s
=> CACHED [build 3/15] WORKDIR /app 0.0s
=> CACHED [build 4/15] RUN mix local.hex --force && mix local.rebar --force 0.0s
=> [build 5/15] COPY mix.exs mix.lock ./ 0.2s
=> [build 6/15] COPY config config 0.0s
=> [build 7/15] RUN mix deps.get --only prod 1.9s
=> [build 8/15] RUN mix deps.compile 68.0s
=> [build 9/15] COPY priv priv 0.0s
=> [build 10/15] COPY assets assets 0.0s
=> [build 11/15] RUN mix assets.deploy 2.1s
=> [build 12/15] RUN mix phx.digest 1.3s
=> [build 13/15] COPY lib lib 0.0s
=> [build 14/15] COPY rel rel 0.0s
=> ERROR [build 15/15] RUN mix do compile, release 1.6s
------
> [build 15/15] RUN mix do compile, release:
#23 1.077 Compiling 39 files (.ex)
#23 1.574
#23 1.574 == Compilation error in file lib/auth_web/router.ex ==
#23 1.574 ** (RuntimeError) No AUTH_API_KEY set, find out how at: https://git.io/JJ6sS
#23 1.574 (auth_plug 1.4.7) lib/helpers.ex:40: AuthPlug.Helpers.check_environment_vars/0
#23 1.574 (auth_plug 1.4.7) lib/auth_plug.ex:33: AuthPlug.init/1
#23 1.574 (plug 1.12.1) lib/plug/builder.ex:318: Plug.Builder.init_module_plug/4
#23 1.574 (plug 1.12.1) lib/plug/builder.ex:302: anonymous fn/5 in Plug.Builder.compile/3
#23 1.574 (elixir 1.12.1) lib/enum.ex:2356: Enum."-reduce/3-lists^foldl/2-0-"/3
#23 1.574 (plug 1.12.1) lib/plug/builder.ex:300: Plug.Builder.compile/3
#23 1.574 lib/auth_web/router.ex:35: (module)
------
Error failed to fetch an image or build from source: error building: executor failed running [/bin/sh -c mix do compile, release]: exit code: 1 More tomorrow. |
one more try:
Looks like we need to dig into the release migrate ... ⏳ |
unclear why it failed this time ... 🤷♂️ |
|
Thanks @SimonLab added that line of config last night: Rather than continuing to bash my head against the brick wall with trying to get the |
PR #173 contains all these enhancements. https://auth.dwyl.com/ works as expected and it's fast! |
This is working on Fly.io: https://auth.dwyl.com 🚀 Closing. ✅ |
Our hits (side) project https://hits.dwyl.com/ has been running on Fly.io for the past 3 months without any issues.
See: dwyl/learn-devops#76 and dwyl/hits#132 ✅
Todo
auth
to Fly.io with all-new Google & GitHub Auth API Keysseeds.exs
to init the DB seeds.exs ... tidy/improve initialising data into auth db #174main
to Fly.ioOn
prod
we want additional security/restrictions e.g. Restricting who can see/people
#171The text was updated successfully, but these errors were encountered: