Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost

NFTCDN_DOMAIN=mynftcdndomain
NFTCDN_KEY=yournftcdndomainhere=
ALLOW_REGISTRATION=true
ALLOW_PASSWORD_CHANGE=true
VITE_APP_ENV=local

LOG_CHANNEL=stack
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug
Expand All @@ -13,7 +19,7 @@ DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=gatekeepermetamorphosis
DB_USERNAME=root
DB_PASSWORD=
DB_PASSWORD=rootpassword

BROADCAST_DRIVER=log
CACHE_DRIVER=file
Expand Down
67 changes: 67 additions & 0 deletions .env.testing
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
APP_NAME=GateKeeper
APP_ENV=testing
APP_KEY=base64:ScbTyDAmfxPaqXuNfzEA5zJ9iPxyC97lwXw5Wi8OyNw=
APP_DEBUG=true
APP_URL=http://localhost
APP_SERVICE=gatekeeper.app

NFTCDN_DOMAIN=yournftcdndomain
NFTCDN_KEY=yournftcdnkeyhere=
ALLOW_REGISTRATION=false
ALLOW_PASSWORD_CHANGE=false
VITE_APP_ENV=testing

LOG_CHANNEL=stack
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug

DB_CONNECTION=sqlite
DB_DATABASE=:memory:
DB_HOST=localhost
DB_PORT=3306
DB_USERNAME=root
DB_PASSWORD=rootpassword

BROADCAST_DRIVER=log
CACHE_DRIVER=file
FILESYSTEM_DISK=local
QUEUE_CONNECTION=sync
SESSION_DRIVER=database
SESSION_LIFETIME=120

MEMCACHED_HOST=127.0.0.1

REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379

MAIL_MAILER=smtp
MAIL_HOST=mailpit
MAIL_PORT=1025
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS="hello@example.com"
MAIL_FROM_NAME="${APP_NAME}"

AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=
AWS_USE_PATH_STYLE_ENDPOINT=false

PUSHER_APP_ID=
PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_HOST=
PUSHER_PORT=443
PUSHER_SCHEME=https
PUSHER_APP_CLUSTER=mt1

VITE_APP_NAME="${APP_NAME}"
VITE_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
VITE_PUSHER_HOST="${PUSHER_HOST}"
VITE_PUSHER_PORT="${PUSHER_PORT}"
VITE_PUSHER_SCHEME="${PUSHER_SCHEME}"
VITE_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"
VITE_DEV_SERVER_URL=http://localhost:5173
44 changes: 44 additions & 0 deletions .github/workflows/ci-staging.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: CI (Staging PR)
on:
pull_request:
branches:
- staging
jobs:
php-tests:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.3
tools: composer:v2
coverage: none

- name: Install PHP dependencies (with dev)
run: composer install --no-interaction --prefer-dist --optimize-autoloader

- name: Prepare .env for tests
run: |
cp .env.example .env
php artisan key:generate
env:
APP_ENV: testing

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'

- name: Install frontend deps & build
run: |
npm ci
npm run build

# If you have tests, this is where they run
- name: Run Laravel test suite
run: php artisan test
2 changes: 1 addition & 1 deletion app/Http/Controllers/CheckinController.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function store(StoreCheckinRequest $request, string $event_uuid): JsonRes
// throughout an event
return response()->json([
'message' => 'Ticket has already been checked in!'
], 401);
], 400);
}

// Since we've arrive here it is probably safe to insert the "checkin"
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/CheckoutController.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public function store(StoreCheckoutRequest $request, string $event_uuid): JsonRe
// then we can't very well add a new checkout can we?
return response()->json([
'message' => 'Ticket has not been checked in!'
], 401);
], 400);
}

// Since we've arrive here it is probably safe to insert the "checkin"
Expand Down
40 changes: 0 additions & 40 deletions app/Http/Controllers/EventCheckinController.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,22 +26,6 @@ public function index(Request $request)
compact('team', 'events'));
}

/**
* Show the form for creating a new resource.
*/
public function create()
{
//
}

/**
* Store a newly created resource in storage.
*/
public function store(Request $request)
{
//
}

/**
* Display the specified resource.
*/
Expand All @@ -54,28 +38,4 @@ public function show(Request $request, string $event_uuid)
->render($request, 'ScanTickets/Show',
compact('event'));
}

/**
* Show the form for editing the specified resource.
*/
public function edit(string $id)
{
//
}

/**
* Update the specified resource in storage.
*/
public function update(Request $request, string $id)
{
//
}

/**
* Remove the specified resource from storage.
*/
public function destroy(string $id)
{
//
}
}
35 changes: 0 additions & 35 deletions app/Http/Controllers/EventPolicyController.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,6 @@

class EventPolicyController extends Controller {

/**
* Display a listing of the resource.
*/
public function index(Event $event) {
//
}

/**
* Show the form for creating a new resource.
*/
public function create(Event $event) {
//
}

/**
* Store a newly created resource in storage.
*/
Expand All @@ -48,27 +34,6 @@ public function store(Request $request, string $eventUUID) {
return back(303);
}

/**
* Display the specified resource.
*/
public function show(Event $event, Policy $policy) {
//
}

/**
* Show the form for editing the specified resource.
*/
public function edit(Event $event, Policy $policy) {
//
}

/**
* Update the specified resource in storage.
*/
public function update(Request $request, Event $event, Policy $policy) {
//
}

/**
* Remove the specified resource from storage.
*/
Expand Down
Loading