-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add gh-actions and supervisor config
Signed-off-by: Fery Wardiyanto <[email protected]>
- Loading branch information
1 parent
f0bd797
commit 03aac40
Showing
3 changed files
with
53 additions
and
15 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 |
---|---|---|
|
@@ -15,7 +15,7 @@ env: | |
# AWS_ENDPOINT: 'https://is3.cloudhost.id' | ||
# AWS_DEFAULT_REGION: 'ap-southeast-3' | ||
# AWS_BUCKET: creasi-staging | ||
MAIL_FROM_ADDRESS: devtest@creasi.co | ||
MAIL_FROM_ADDRESS: devtest@creasi.dev | ||
SENTRY_LARAVEL_DSN: ${{ secrets.SENTRY_DSN }} | ||
SENTRY_TRACE_QUEUE_ENABLED: true | ||
SENTRY_TRACES_SAMPLE_RATE: 1.0 | ||
|
@@ -103,7 +103,7 @@ jobs: | |
extensions: curl, dom, gd, igbinary, imagick, intl, libxml, mbstring, pcntl, pdo, pdo_pgsql, redis, zip | ||
ini-values: error_reporting=E_ALL | ||
tools: composer:v2 | ||
coverage: xdebug | ||
coverage: none | ||
env: | ||
REDIS_CONFIGURE_OPTS: --enable-redis --enable-redis-igbinary | ||
|
||
|
@@ -132,7 +132,9 @@ jobs: | |
with: | ||
timeout_minutes: 5 | ||
max_attempts: 3 | ||
command: composer update --prefer-dist --no-interaction --no-progress | ||
command: | | ||
composer config -g github-oauth.github.com ${{ secrets.PAT }} | ||
composer update --prefer-dist --no-interaction --no-progress | ||
- name: Run unit tests | ||
run: php artisan test | ||
|
@@ -210,7 +212,9 @@ jobs: | |
with: | ||
timeout_minutes: 5 | ||
max_attempts: 3 | ||
command: composer update --prefer-dist --no-interaction --no-progress | ||
command: | | ||
composer config -g github-oauth.github.com ${{ secrets.PAT }} | ||
composer update --prefer-dist --no-interaction --no-progress | ||
- name: Setup BrowserStack env # Invokes the setup-env action | ||
uses: browserstack/github-actions/setup-env@master | ||
|
@@ -261,6 +265,15 @@ jobs: | |
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: 8.0 | ||
extensions: curl, intl, libxml, mbstring, pcntl, ssh2, zip | ||
ini-values: error_reporting=E_ALL | ||
tools: composer:v2 | ||
coverage: none | ||
|
||
- name: Prepare | ||
run: | | ||
[[ ! -d $HOME/.ssh ]] && mkdir $HOME/.ssh | ||
|
@@ -270,17 +283,21 @@ jobs: | |
chmod 600 $HOME/.ssh/* && ls -al $HOME/.ssh/ | ||
git config user.name "Creasi.HQ" && git config user.email "[email protected]" | ||
- name: Install dependencies | ||
uses: nick-invision/retry@v2 | ||
with: | ||
timeout_minutes: 5 | ||
max_attempts: 3 | ||
command: | | ||
composer config -g github-oauth.github.com ${{ secrets.PAT }} | ||
composer update --prefer-dist --no-interaction --no-progress | ||
- name: Download assets | ||
id: download | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: public | ||
path: public/build | ||
|
||
# - name: Deploy repo | ||
# run: | | ||
# git fetch [email protected]:~/git/wanho.git | ||
# git push -fu [email protected]:~/git/wanho.git HEAD:master | ||
|
||
- name: Deploy assets | ||
run: rsync -zrtv public/build creasi.co:skeleton.creasi.dev/public/ | ||
- name: Deploy repo | ||
run: ./vendor/bin/dep deploy |
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,20 @@ | ||
[group:creasi-skeleton] | ||
programs=skeleton-queue,skeleton-schedule | ||
|
||
[program:skeleton-queue] | ||
command=php /var/www/skeleton/current/artisan queue:work --timeout=360 --max-time=1200 --tries=3 | ||
autostart=true | ||
autorestart=true | ||
startretries=3 | ||
startsecs=5 | ||
# stdout_logfile=/var/log/creasi/%(program_name)s.log | ||
stderr_logfile=/var/log/creasi/%(program_name)s.err.log | ||
|
||
[program:skeleton-schedule] | ||
command=php /var/www/skeleton/current/artisan schedule:work | ||
autostart=true | ||
autorestart=true | ||
startretries=3 | ||
startsecs=1 | ||
# stdout_logfile=/var/log/creasi/%(program_name)s.log | ||
stderr_logfile=/var/log/creasi/%(program_name)s.err.log |
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