Separated laravel app to its own folder (#540)
This commit is contained in:
parent
39b8df5eed
commit
5bd1dda504
8
.babelrc
8
.babelrc
|
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
"presets": [
|
|
||||||
"@babel/preset-env"
|
|
||||||
],
|
|
||||||
"plugins": [
|
|
||||||
"@babel/plugin-syntax-dynamic-import"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
|
|
@ -6,7 +6,6 @@ on:
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
code_lint:
|
code_lint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: Run code linters
|
name: Run code linters
|
||||||
|
|
@ -36,15 +35,19 @@ jobs:
|
||||||
coverage: none
|
coverage: none
|
||||||
|
|
||||||
- name: Prepare the environment
|
- name: Prepare the environment
|
||||||
|
working-directory: ./api
|
||||||
run: cp .env.example .env
|
run: cp .env.example .env
|
||||||
|
|
||||||
- name: Install composer dependencies
|
- name: Install composer dependencies
|
||||||
|
working-directory: ./api
|
||||||
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
||||||
|
|
||||||
- name: Directory permissions
|
- name: Directory permissions
|
||||||
|
working-directory: ./api
|
||||||
run: chmod -R 777 storage bootstrap/cache
|
run: chmod -R 777 storage bootstrap/cache
|
||||||
|
|
||||||
- name: Run PHP lint check
|
- name: Run PHP lint check
|
||||||
|
working-directory: ./api
|
||||||
run: ./vendor/bin/pint --test
|
run: ./vendor/bin/pint --test
|
||||||
|
|
||||||
tests:
|
tests:
|
||||||
|
|
@ -100,7 +103,7 @@ jobs:
|
||||||
password: postgres
|
password: postgres
|
||||||
database: postgres
|
database: postgres
|
||||||
- connection: mysql
|
- connection: mysql
|
||||||
host: '127.0.0.1'
|
host: "127.0.0.1"
|
||||||
port: 3306
|
port: 3306
|
||||||
user: root
|
user: root
|
||||||
password: test
|
password: test
|
||||||
|
|
@ -133,12 +136,14 @@ jobs:
|
||||||
coverage: none
|
coverage: none
|
||||||
|
|
||||||
- name: Prepare the environment
|
- name: Prepare the environment
|
||||||
run: cp .env.example .env
|
run: cp api/.env.example api/.env
|
||||||
|
|
||||||
- name: Install composer dependencies
|
- name: Install composer dependencies
|
||||||
|
working-directory: ./api
|
||||||
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
||||||
|
|
||||||
- name: Directory permissions
|
- name: Directory permissions
|
||||||
|
working-directory: ./api
|
||||||
run: chmod -R 777 storage bootstrap/cache
|
run: chmod -R 777 storage bootstrap/cache
|
||||||
|
|
||||||
- name: Run tests (Unit and Feature)
|
- name: Run tests (Unit and Feature)
|
||||||
|
|
@ -154,6 +159,7 @@ jobs:
|
||||||
- name: "Archive log results"
|
- name: "Archive log results"
|
||||||
if: always()
|
if: always()
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
|
working-directory: ./api
|
||||||
with:
|
with:
|
||||||
name: log results
|
name: log results
|
||||||
path: storage/logs/laravel.log
|
path: storage/logs/laravel.log
|
||||||
|
|
@ -172,7 +178,7 @@ jobs:
|
||||||
- name: Set up Node.js
|
- name: Set up Node.js
|
||||||
uses: actions/setup-node@v1
|
uses: actions/setup-node@v1
|
||||||
with:
|
with:
|
||||||
node-version: '20'
|
node-version: "20"
|
||||||
|
|
||||||
- uses: actions/cache@v2
|
- uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
|
|
@ -230,12 +236,15 @@ jobs:
|
||||||
coverage: none
|
coverage: none
|
||||||
|
|
||||||
- name: Prepare the environment
|
- name: Prepare the environment
|
||||||
|
working-directory: ./api
|
||||||
run: cp .env.example .env
|
run: cp .env.example .env
|
||||||
|
|
||||||
- name: Install composer dependencies
|
- name: Install composer dependencies
|
||||||
|
working-directory: ./api
|
||||||
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
run: composer install --prefer-dist --no-interaction --no-progress --ignore-platform-reqs --optimize-autoloader
|
||||||
|
|
||||||
- name: Directory permissions
|
- name: Directory permissions
|
||||||
|
working-directory: ./api
|
||||||
run: chmod -R 777 storage bootstrap/cache
|
run: chmod -R 777 storage bootstrap/cache
|
||||||
|
|
||||||
- name: Trigger front-end deployment
|
- name: Trigger front-end deployment
|
||||||
|
|
@ -244,10 +253,12 @@ jobs:
|
||||||
curl -X POST -d {} "$URL" -H "Content-Type: application/json"
|
curl -X POST -d {} "$URL" -H "Content-Type: application/json"
|
||||||
|
|
||||||
- name: Created encrypted .env file before deployment
|
- name: Created encrypted .env file before deployment
|
||||||
|
working-directory: ./api
|
||||||
run: |
|
run: |
|
||||||
echo "${{ secrets.ENCRYPTED_ENV_FILE }}" >> .env.production.encrypted
|
echo "${{ secrets.ENCRYPTED_ENV_FILE }}" >> .env.production.encrypted
|
||||||
|
|
||||||
- name: Deploy back-end to production
|
- name: Deploy back-end to production
|
||||||
|
working-directory: ./api
|
||||||
run: php vendor/bin/vapor deploy api-production --commit="${GITHUB_SHA}" --message="${GITHUB_REF}"
|
run: php vendor/bin/vapor deploy api-production --commit="${GITHUB_SHA}" --message="${GITHUB_REF}"
|
||||||
env:
|
env:
|
||||||
VAPOR_API_TOKEN: ${{ secrets.VAPOR_API_TOKEN }}
|
VAPOR_API_TOKEN: ${{ secrets.VAPOR_API_TOKEN }}
|
||||||
|
|
|
||||||
|
|
@ -1,33 +1,11 @@
|
||||||
/node_modules
|
|
||||||
/public/hot
|
|
||||||
/public/storage
|
|
||||||
/storage/*.key
|
|
||||||
/storage/clockwork
|
|
||||||
/vendor
|
|
||||||
.env
|
|
||||||
.env.production
|
|
||||||
.env.api-production
|
|
||||||
.env.backup
|
|
||||||
.env.testing
|
|
||||||
.env.dusk.local
|
|
||||||
.env.api-*
|
|
||||||
.phpunit.result.cache
|
|
||||||
.idea/*
|
.idea/*
|
||||||
Homestead.json
|
Homestead.json
|
||||||
Homestead.yaml
|
Homestead.yaml
|
||||||
npm-debug.log
|
npm-debug.log
|
||||||
yarn-error.log
|
yarn-error.log
|
||||||
phpunit.dusk.xml
|
phpunit.dusk.xml
|
||||||
/public/dist
|
|
||||||
/public/build
|
|
||||||
/public/mix-manifest.json
|
|
||||||
/public/sitemap.xml
|
|
||||||
.DS_Store
|
.DS_Store
|
||||||
public/.DS_Store
|
public/.DS_Store
|
||||||
*.DS_Store
|
*.DS_Store
|
||||||
.vapor/
|
|
||||||
.env.production
|
|
||||||
.env.staging
|
|
||||||
_ide_helper.php
|
|
||||||
docker-compose.override.yml
|
docker-compose.override.yml
|
||||||
/.make.*
|
/.make.*
|
||||||
|
|
|
||||||
13
.styleci.yml
13
.styleci.yml
|
|
@ -1,13 +0,0 @@
|
||||||
php:
|
|
||||||
preset: laravel
|
|
||||||
disabled:
|
|
||||||
- no_unused_imports
|
|
||||||
finder:
|
|
||||||
not-name:
|
|
||||||
- index.php
|
|
||||||
- server.php
|
|
||||||
js:
|
|
||||||
finder:
|
|
||||||
not-name:
|
|
||||||
- webpack.mix.js
|
|
||||||
css: true
|
|
||||||
18
README.md
18
README.md
|
|
@ -103,19 +103,6 @@ OpnForm can be easily set up using Docker. Pre-built images are available on Doc
|
||||||
#### Quick Start
|
#### Quick Start
|
||||||
|
|
||||||
1. Clone the repository:
|
1. Clone the repository:
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
```
|
|
||||||
git clone https://github.com/JhumanJ/OpnForm.git
|
|
||||||
cd OpnForm
|
|
||||||
```
|
|
||||||
|
|
||||||
2. Set up environment files:
|
|
||||||
|
|
||||||
```
|
|
||||||
cp .env.docker .env
|
|
||||||
cp client/.env.docker client/.env
|
|
||||||
=======
|
|
||||||
|
|
||||||
```
|
```
|
||||||
git clone https://github.com/JhumanJ/OpnForm.git
|
git clone https://github.com/JhumanJ/OpnForm.git
|
||||||
|
|
@ -126,7 +113,6 @@ OpnForm can be easily set up using Docker. Pre-built images are available on Doc
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
./scripts/setup-env.sh --docker
|
./scripts/setup-env.sh --docker
|
||||||
>>>>>>> 0a9400492674212cdabcd4821ee87483b28735e5
|
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Start the application:
|
3. Start the application:
|
||||||
|
|
@ -177,7 +163,7 @@ For development or customization, you can build the Docker images locally:
|
||||||
2. Create a docker-compose override file:
|
2. Create a docker-compose override file:
|
||||||
|
|
||||||
```
|
```
|
||||||
cp docker-compose.override.yml.example docker-compose.override.yml
|
touch docker-compose.override.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
Edit the `docker-compose.override.yml` file to use your locally built images:
|
Edit the `docker-compose.override.yml` file to use your locally built images:
|
||||||
|
|
@ -188,6 +174,8 @@ For development or customization, you can build the Docker images locally:
|
||||||
image: opnform-api:local
|
image: opnform-api:local
|
||||||
ui:
|
ui:
|
||||||
image: opnform-ui:local
|
image: opnform-ui:local
|
||||||
|
api-worker:
|
||||||
|
image: opnform-api:local
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Start the application:
|
3. Start the application:
|
||||||
|
|
|
||||||
|
|
@ -18,11 +18,11 @@ SESSION_LIFETIME=120
|
||||||
MAIL_MAILER=log
|
MAIL_MAILER=log
|
||||||
MAIL_HOST=
|
MAIL_HOST=
|
||||||
MAIL_PORT=
|
MAIL_PORT=
|
||||||
MAIL_USERNAME=
|
MAIL_USERNAME=your@email.com
|
||||||
MAIL_PASSWORD=
|
MAIL_PASSWORD=
|
||||||
MAIL_ENCRYPTION=
|
MAIL_ENCRYPTION=
|
||||||
MAIL_FROM_ADDRESS=
|
MAIL_FROM_ADDRESS=your@email.com
|
||||||
MAIL_FROM_NAME=
|
MAIL_FROM_NAME=OpnForm
|
||||||
|
|
||||||
AWS_ACCESS_KEY_ID=
|
AWS_ACCESS_KEY_ID=
|
||||||
AWS_SECRET_ACCESS_KEY=
|
AWS_SECRET_ACCESS_KEY=
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
/node_modules
|
||||||
|
/public/hot
|
||||||
|
/public/storage
|
||||||
|
/storage/*.key
|
||||||
|
/storage/clockwork
|
||||||
|
/vendor
|
||||||
|
.env
|
||||||
|
.env.production
|
||||||
|
.env.api-production
|
||||||
|
.env.backup
|
||||||
|
.env.testing
|
||||||
|
.env.dusk.local
|
||||||
|
.env.api-*
|
||||||
|
.env.docker.local
|
||||||
|
.phpunit.result.cache
|
||||||
|
.idea/*
|
||||||
|
Homestead.json
|
||||||
|
Homestead.yaml
|
||||||
|
npm-debug.log
|
||||||
|
yarn-error.log
|
||||||
|
phpunit.dusk.xml
|
||||||
|
/public/dist
|
||||||
|
/public/build
|
||||||
|
/public/mix-manifest.json
|
||||||
|
/public/sitemap.xml
|
||||||
|
.DS_Store
|
||||||
|
public/.DS_Store
|
||||||
|
*.DS_Store
|
||||||
|
.vapor/
|
||||||
|
.env.production
|
||||||
|
.env.staging
|
||||||
|
_ide_helper.php
|
||||||
|
docker-compose.override.yml
|
||||||
|
/.make.*
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue