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
16 changes: 0 additions & 16 deletions .gitignore

This file was deleted.

45 changes: 37 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,42 @@
sudo: required

services:
- docker
- docker

cache:
yarn: true
directories:
- admin/node_modules
- client/node_modules

before_script:
- sudo service mysql stop
- sudo service postgresql stop
- wget https://kubernetes-helm.storage.googleapis.com/helm-v2.6.1-linux-amd64.tar.gz
- tar xzf helm-v2.6.1-linux-amd64.tar.gz
- npm install -g react-scripts
- while sudo lsof -Pi :5432 -sTCP:LISTEN -t; do sleep 1; done

script:
- docker-compose build
- docker-compose run web composer install -o -n
- docker-compose run web bin/console security:check
- docker-compose run web bin/console doctrine:schema:validate --skip-sync
- docker-compose up -d
- docker-compose run web bin/console doctrine:schema:create
- docker-compose run web bin/console hautelook:fixtures:load -n
- docker-compose up -d
- linux-amd64/helm lint api/helm/api/
- sleep 20
- sh -c "cd admin && PUBLIC_URL="/api-demo-admin-test" yarn install && yarn build"
- sh -c "cd client && PUBLIC_URL="/api-demo-client-test" yarn install && yarn build"
- docker-compose exec php composer install -o -n
- docker-compose exec php bin/console security:check
- docker-compose exec php bin/console doctrine:schema:validate --skip-sync
- docker-compose exec php bin/console doctrine:schema:drop --force
- docker-compose exec php bin/console doctrine:schema:create
- docker-compose exec php bin/console hautelook:fixtures:load -n
- docker-compose exec php bin/console doctrine:schema:drop --env=test --force
- docker-compose exec php bin/console cache:warmup --env=test
- docker-compose exec php bin/behat
- curl http://localhost
- curl http://localhost:81
- curl http://localhost:8080
- curl http://localhost:8081
- curl -k https://localhost
- curl -k https://localhost:444
- curl -k https://localhost:8443
- curl -k https://localhost:8444
63 changes: 0 additions & 63 deletions Dockerfile

This file was deleted.

Empty file modified LICENSE
100644 → 100755
Empty file.
7 changes: 4 additions & 3 deletions README.md
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,21 @@ Installation (recommended)

$ git clone https://github.com/api-platform/demo.git


$ docker-compose up
```

And go to https://localhost

Installation (manual)
=====================

```shell

$ git clone https://github.com/api-platform/demo.git

$ composer install
# Create a user and a database in PostgreSQL and enter the credentials into .env

# Create a user and a database in MySQL and enter the credentials during composer install
$ composer install

$ php bin/console doctrine:schema:update --force
```
10 changes: 10 additions & 0 deletions admin/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
**/*.log
**/._*
**/.DS_Store
**/.gitignore
**/.gitattributes
**/Thumbs.db
**/*.md
**/.dockerignore
Dockerfile*
.env*
1 change: 1 addition & 0 deletions admin/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
REACT_APP_API_ENTRYPOINT=https://localhost:8443
20 changes: 20 additions & 0 deletions admin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# See https://help.github.com/ignore-files/ for more about ignoring files.

# dependencies
/node_modules

# testing
/coverage

# production
/build

# misc
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
13 changes: 13 additions & 0 deletions admin/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM node:9.4-alpine

RUN mkdir -p /usr/src/admin

WORKDIR /usr/src/admin

# Prevent the reinstallation of node modules at every changes in the source code
COPY package.json yarn.lock ./
RUN yarn install

COPY . ./

CMD yarn start
Loading