fideloper
Repos
88
Followers
1223
Following
10

Laravel Proxy Package for handling sessions when behind load balancers or other intermediaries.

7299
106

Events

create tag
fideloper create tag v0.0.401
Created at 3 days ago

machines: preserve existing config on deploy

Merge pull request #1311 from ignoramous/mrun

machines: preserve existing config on deploy

Created at 3 days ago
closed issue
`fly deploy` resets vm size to shared-cpu-1x 256MB on machine-based apps

Describe the bug

Was asked to report here from the forum thread: https://community.fly.io/t/preview-deploying-applications-on-machines-with-flyctl/6171/8?u=lewis

I had my app set to use 2048MB memory and 2 shared cpus through fly machine update. But running fly deploy seems to have reset it to 1 shared cpu and 256MB memory.

This is reproducible every time I deploy. For now I've been working around it by updating my CI script to set the size immediately after each deploy. Works for now since there's barely any traffic, but obviously not sustainable.

Doesn't seem to be OS specific since it happens when I do fly deploy in CI (linux) as well as locally (macOS).

  • Operating system: macOS Monterey 12.6
  • fly version: fly v0.0.396 darwin/arm64 Commit: edf8f512 BuildDate: 2022-09-23T19:34:38Z

** Paste your fly.toml

app = "reflame-deployer"

[build]

[http_service]
  internal_port = 58001
  force_https = true

  [http_service.concurrency]
    hard_limit = 10
    soft_limit = 2
    type = "requests"

[deploy]
Created at 3 days ago
pull request closed
machines: preserve existing config on deploy

Ref: https://github.com/superfly/flyctl/issues/1310

Created at 3 days ago
issue comment
machines: preserve existing config on deploy

Tested this PR locally and it seems to work great!

The web UI never updated as a result of me running fly m update <machineid> --cpus 2 --memory 2048, but SSHing and and running htop / free -h showed me that it did indeed scale, and stayed scaled after a deployment.

I'm curious if you've used other commands to scale a machine?

Created at 3 days ago
issue comment
Include a database section in laravel docs that provides guidance on …

Looks good here! Merge it whenever you'd like (if you want Johannes to take a look)

Created at 3 days ago
issue comment
Include a database section in laravel docs that provides guidance on …

Looks great! I have a few cleanup things mentioned above.

Created at 4 days ago

a note on getting mysql8 to run on the free tier

Created at 5 days ago

fix: Add schedule to flyctl

fix: rely on flyd to validate

fix: Move logic to determinemachineconfig

added alias volume to fly volumes

Omit empty check fields

Merge pull request #1226 from superfly/feat/add-schedule-flag

Add schedule flag to machine run

fix: Add wait for stopped

Merge pull request #1277 from superfly/checks-omitempty

Omit empty check fields

Fixing vm-size bug (#1279)

  • Fixing vm-size bug

  • Cleanup

  • Remove log

fix: Validate action to catch errors

Merge pull request #1278 from superfly/fix/update-scheduled-machine

fix: Add wait for stopped

fix: typo

Merge pull request #1280 from superfly/fix/typo

fix: typo

fix toml parsing for machine top level checks

Merge pull request #1281 from superfly/machine-checks

fix toml parsing for machine top level checks

Unmarshall machine check statuses

fix: Add details on machine update

fix: Show updated config

Defer lease release (#1283)

wip

Created at 5 days ago
issue comment
Small changes to the getting-started docs

Looks great, merge it when you're ready!

Created at 5 days ago

disgusting mix of tabs and spaces rectified. can't be having that.

Created at 1 week ago
delete branch
fideloper delete branch add_post_deployment_section_to_laravel_docs
Created at 1 week ago
issue comment
X-Forwarded-For ignored

Hi!

You'll need to share some more information about your configuration to get more help I think. This doesn't sound like a Laravel issue tho.

  1. Is Nginx your load balancer or is it something hosted from a service, perhaps AWS?
  2. Does the load balancer not add X-Forwarded-* headers itself?

If the load balancer is setting those headers, then Nginx should be seeing and transforming those headers for PHP to see automatically (in $_SERVER['HTTP_X_Forwarded_For'], which Laravel/Symfony classes then read/transform into a Request object).

Some general info:

When Nginx is sending requests over fastcgi to PHP-FPM, it's not setting headers but instead setting fastcgi "parameters".

In PHP, all HTTP headers start with HTTP_, and they populate the $_SERVER global.

So, to add an HTTP header that PHP-FPM sees, it usually looks like this:

location ~ \.php$ {
    fastcgi_param HTTP_X_FORWARDED_FOR $whatever;
    // and so on...
}

Note that this means when you say:

It is received correctly by PHP ($_SERVER["X-Forwarded-For"] is the correct client IP).

That's actually incorrect - $_SERVER should have a value of $_SERVER["HTTP_X_Forwarded_For"]

So, overall, something sounds funky in your configuration. Having to add HTTP_ in your header sounds like it's related to getting the correct value into PHP (which Laravel would then read).

Are you using PHP-FPM? Perhaps you're using Octane?

Created at 1 week ago
issue comment
Add info on console and logs access through post deployment section i…

Looks good! Merge it when you're ready!

Created at 1 week ago

Update cron-and-queues.html.md

Merge pull request #341 from thejager/patch-2

Update cron-and-queues.html.md

Created at 1 week ago
pull request closed
Update cron-and-queues.html.md
Created at 1 week ago
issue comment
Update cron-and-queues.html.md

Good catch!

Created at 1 week ago