-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 9d80d13
Showing
9 changed files
with
1,559 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?php | ||
namespace PHPSTORM_META { | ||
override(\Psr\Container\ContainerInterface::get(0), | ||
map([ | ||
'' => '@', | ||
]) | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
web: vendor/bin/heroku-php-apache2 web/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Heroku CLI Example using Scout PHP | ||
|
||
Simple Heroku CLI command example for Scout | ||
|
||
## Running Heroku | ||
|
||
NOTE: add your scout key to the example below: | ||
|
||
```bash | ||
heroku create | ||
heroku config:set SCOUT_KEY=<add your scout key here> SCOUT_NAME=heroku-cli-example SCOUT_MONITOR=true | ||
git push heroku main | ||
heroku ps:scale web=0 # Not using web nodes for this example | ||
heroku run php long-running-process.php | ||
``` | ||
|
||
## Running Locally | ||
|
||
NOTE: add your scout key to the example below: | ||
|
||
```bash | ||
export SCOUT_KEY=<add your scout key here> | ||
export SCOUT_NAME=heroku-cli-example | ||
export SCOUT_MONITOR=true | ||
|
||
LONG_PROCESS_ITERATION_COUNT=3 WAIT_AFTER_ITERATION_SECS=1 SINGLE_ITERATION_SLEEP_SECS=1 php long-running-process.php | ||
php short-process.php | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"name": "asgrim/scout-apm-php-heroku-cli-example", | ||
"description": "Example application for testing Heroku CLI", | ||
"type": "project", | ||
"require": { | ||
"php": "8.1.*", | ||
"scoutapp/scout-apm-php": "^7.0", | ||
"monolog/monolog": "^2.3", | ||
"psr/log": "^1.0", | ||
"laminas/laminas-servicemanager": "^3.10", | ||
"psr/container": "^1.0" | ||
}, | ||
"license": "MIT", | ||
"autoload": { | ||
"psr-4": { | ||
"Asgrim\\ScoutApmPhpHerokuCliExample\\": "src/" | ||
} | ||
}, | ||
"authors": [ | ||
{ | ||
"name": "James Titcumb", | ||
"email": "[email protected]" | ||
} | ||
] | ||
} |
Oops, something went wrong.