From bb762ec5f88207525bd0616ace2d26c7a85fd4ec Mon Sep 17 00:00:00 2001 From: Ostapcuka Date: Wed, 9 Jun 2021 14:04:57 +0100 Subject: [PATCH 1/5] Added Test JMeter Test Plan --- pizzahouse/jmeter/jmetertestplan.jmx | 126 +++++++++++++++++++ pizzahouse/public/js/app.js | 4 +- pizzahouse/resources/views/welcome.blade.php | 2 +- 3 files changed, 129 insertions(+), 3 deletions(-) create mode 100644 pizzahouse/jmeter/jmetertestplan.jmx diff --git a/pizzahouse/jmeter/jmetertestplan.jmx b/pizzahouse/jmeter/jmetertestplan.jmx new file mode 100644 index 0000000..9f46803 --- /dev/null +++ b/pizzahouse/jmeter/jmetertestplan.jmx @@ -0,0 +1,126 @@ + + + + + + false + true + false + + + + + + + + continue + + false + 2 + + 5 + 1 + false + + + true + + + + + + + 127.0.0.1 + 8000 + + + + GET + true + false + true + false + + + + + + + + + + 127.0.0.1 + 8000 + + + pizzas/create + GET + true + false + true + false + + + + + + + + + + 127.0.0.1 + 8000 + + + login + GET + true + false + true + false + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + + + diff --git a/pizzahouse/public/js/app.js b/pizzahouse/public/js/app.js index 92097d3..8fb6496 100644 --- a/pizzahouse/public/js/app.js +++ b/pizzahouse/public/js/app.js @@ -49685,8 +49685,8 @@ __webpack_require__.r(__webpack_exports__); /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { -__webpack_require__(/*! C:\Users\Shaun\Documents\Tutorial Code\YouTube\course-files\laravel-beginners-tutorial\pizzahouse\resources\js\app.js */"./resources/js/app.js"); -module.exports = __webpack_require__(/*! C:\Users\Shaun\Documents\Tutorial Code\YouTube\course-files\laravel-beginners-tutorial\pizzahouse\resources\sass\app.scss */"./resources/sass/app.scss"); +__webpack_require__(/*! D:\xampp\htdocs\laravel-beginners-tutorial\pizzahouse\resources\js\app.js */"./resources/js/app.js"); +module.exports = __webpack_require__(/*! D:\xampp\htdocs\laravel-beginners-tutorial\pizzahouse\resources\sass\app.scss */"./resources/sass/app.scss"); /***/ }) diff --git a/pizzahouse/resources/views/welcome.blade.php b/pizzahouse/resources/views/welcome.blade.php index 53e14e1..11ac011 100644 --- a/pizzahouse/resources/views/welcome.blade.php +++ b/pizzahouse/resources/views/welcome.blade.php @@ -22,7 +22,7 @@ The North's Best Pizzas

{{ session('mssg') }}

- Order a Pizza + Order a Pizza for you and your friends! @endsection From 920da5e8401d0d5c2d0b911968f33433e341448d Mon Sep 17 00:00:00 2001 From: Marina <54036167+MarinaOstaa@users.noreply.github.com> Date: Wed, 9 Jun 2021 15:08:24 +0100 Subject: [PATCH 2/5] Create Dockerfile --- pizzahouse/Dockerfile | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 pizzahouse/Dockerfile diff --git a/pizzahouse/Dockerfile b/pizzahouse/Dockerfile new file mode 100644 index 0000000..6a86b8c --- /dev/null +++ b/pizzahouse/Dockerfile @@ -0,0 +1,2 @@ +FROM tomsik68/xampp +COPY . /www From d47d4a513952670c7adf16e31143e2a8409ad59d Mon Sep 17 00:00:00 2001 From: Marina <54036167+MarinaOstaa@users.noreply.github.com> Date: Wed, 9 Jun 2021 15:37:15 +0100 Subject: [PATCH 3/5] Update welcome.blade.php --- pizzahouse/resources/views/welcome.blade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pizzahouse/resources/views/welcome.blade.php b/pizzahouse/resources/views/welcome.blade.php index 11ac011..9f49913 100644 --- a/pizzahouse/resources/views/welcome.blade.php +++ b/pizzahouse/resources/views/welcome.blade.php @@ -22,7 +22,7 @@ The North's Best Pizzas

{{ session('mssg') }}

- Order a Pizza for you and your friends! + Order a Pizza for you and your friends! :) @endsection From e06eb81b79ebe6b165f10f59ab173396c7d50a12 Mon Sep 17 00:00:00 2001 From: Marina <54036167+MarinaOstaa@users.noreply.github.com> Date: Wed, 9 Jun 2021 15:41:20 +0100 Subject: [PATCH 4/5] Create laravel.yml --- .github/workflows/laravel.yml | 68 +++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 .github/workflows/laravel.yml diff --git a/.github/workflows/laravel.yml b/.github/workflows/laravel.yml new file mode 100644 index 0000000..685ca3f --- /dev/null +++ b/.github/workflows/laravel.yml @@ -0,0 +1,68 @@ +name: Laravel + +on: + push: + branches: [ lesson-29 ] + +jobs: + build: + + runs-on: self-hosted + + steps: + - uses: shivammathur/setup-php@15c43e89cdef867065b0213be354c2841860869e + with: + php-version: '8.0' + - uses: actions/checkout@v2 + - name: Copy .env + run: php -r "file_exists('.env') || copy('.env.example', '.env');" + - name: Get composer cache directory + id: composer-cache + run: | + cd ./dist + echo "::set-output name=dir::$(composer config cache-files-dir)" + + - name: Cache composer dependencies + uses: actions/cache@v2 + with: + path: ${{ steps.composer-cache.outputs.dir }} + # Use composer.json for key, if composer.lock is not committed. + # key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: ${{ runner.os }}-composer- + + - name: Install Dependencies + run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist + - name: Generate key + run: php artisan key:generate + - name: Install Node Modules + run: npm install + - name: Directory Permissions + run: chmod -R 777 storage bootstrap/cache + - name: Build SASS + run: npm run prod + # - name: Create Database + # run: | + # mkdir -p database + # touch database/database.sqlite + # - name: Execute tests (Unit and Feature tests) via PHPUnit + # env: + # DB_CONNECTION: sqlite + # DB_DATABASE: database/database.sqlite + # run: vendor/bin/phpunit + deploy-to-test: + needs: build + + runs-on: self-hosted + steps: + - name: Login to Docker Container + uses: docker/login-action@v1 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - run: | + docker pull marinaostaa/demo-app:latest + docker stop myXampp + docker rm myXampp + #docker run -d -p 8080:8080 --name myXampp marinaostaa/demo-app:latest + docker run -d -p 41061:22 -p 41062:80 --name myXampp marinaostaa/demo-app:latest From 0e29f6fc6afd3d1d69c2f289d98722498ff2e8bf Mon Sep 17 00:00:00 2001 From: Marina <54036167+MarinaOstaa@users.noreply.github.com> Date: Wed, 9 Jun 2021 15:44:18 +0100 Subject: [PATCH 5/5] Update laravel.yml --- .github/workflows/laravel.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/laravel.yml b/.github/workflows/laravel.yml index 685ca3f..3f1551f 100644 --- a/.github/workflows/laravel.yml +++ b/.github/workflows/laravel.yml @@ -1,4 +1,4 @@ -name: Laravel +name: Laravel CI on: push: