diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 46d80241f..1740c09fe 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -329,19 +329,16 @@ jobs: - name: backend | docker-compose run: docker-compose -f docker-compose.yml -f docker-compose.test.yml up --detach --no-deps webapp neo4j backend - name: cypress | Fullstack tests + id: e2e-tests run: | yarn install yarn run cypress:run --spec $(cypress/parallel-features.sh ${{ matrix.job }} ${{ env.jobs }} ) ########################################################################## - # UPLOAD SCREENSHOTS & VIDEO ############################################# + # UPLOAD SCREENSHOTS - IF TESTS FAIL ##################################### ########################################################################## - - name: Upload Artifact + - name: Full stack tests | if any test failed, upload screenshots + if: ${{ failure() && steps.e2e-tests.conclusion == 'failure' }} uses: actions/upload-artifact@v3 with: name: cypress-screenshots path: cypress/screenshots/ - - name: Upload Artifact - uses: actions/upload-artifact@v3 - with: - name: cypress-videos - path: cypress/videos/ diff --git a/README.md b/README.md index 8ddf97fe5..06e8d4929 100644 --- a/README.md +++ b/README.md @@ -197,7 +197,8 @@ Prepare database once before you start by running the following command in a sec ```bash # in main folder while docker-compose is up -$ docker-compose exec backend yarn run db:migrate init +$ docker compose exec backend yarn run db:migrate init +$ docker compose exec backend yarn run db:migrate up ``` Then clear and seed database by running the following command as well in the second terminal: diff --git a/backend/README.md b/backend/README.md index 03724ce54..98b0e7218 100644 --- a/backend/README.md +++ b/backend/README.md @@ -81,8 +81,7 @@ More details about our GraphQL playground and how to use it with ocelot.social c ### Database Indexes and Constraints -Database indexes and constraints need to be created when the database and the -backend is running: +Database indexes and constraints need to be created and upgraded when the database and the backend are running: {% tabs %} {% tab title="Docker" %} @@ -98,6 +97,11 @@ $ docker compose exec backend yarn prod:migrate init $ docker compose exec backend /bin/sh -c "yarn prod:migrate init" ``` +```bash +# in main folder with docker compose running +$ docker exec backend yarn run db:migrate up +``` + {% endtab %} {% tab title="Without Docker" %} @@ -107,6 +111,11 @@ $ docker compose exec backend /bin/sh -c "yarn prod:migrate init" yarn run db:migrate init ``` +```bash +# in backend/ with database running (In docker or local) +yarn run db:migrate up +``` + {% endtab %} {% endtabs %} @@ -134,6 +143,8 @@ $ docker exec backend yarn run db:reset $ docker-compose down -v # if container is not running, run this command to set up your database indexes and constraints $ docker exec backend yarn run db:migrate init +# And then upgrade the indexes and const +$ docker exec backend yarn run db:migrate up ``` {% endtab %} diff --git a/cypress/cypress.json b/cypress/cypress.json index dbe8691fa..de323f736 100644 --- a/cypress/cypress.json +++ b/cypress/cypress.json @@ -4,6 +4,7 @@ "ignoreTestFiles": "*.js", "chromeWebSecurity": false, "baseUrl": "http://localhost:3000", + "video":false, "retries": { "runMode": 2, "openMode": 0 diff --git a/deployment/DOCKER_MORE_CLOSELY.md b/deployment/DOCKER_MORE_CLOSELY.md new file mode 100644 index 000000000..67488fe81 --- /dev/null +++ b/deployment/DOCKER_MORE_CLOSELY.md @@ -0,0 +1,33 @@ +# Docker + +## Apple M1 Platform + +***Attention:** For using Docker commands in Apple M1 environments!* + +```bash +# set env variable for your shell +$ export DOCKER_DEFAULT_PLATFORM=linux/amd64 +``` + +For even more informations, see [Docker More Closely](#docker-more-closely) + +### Docker Compose Override File For Apple M1 Platform + +For Docker compose `up` or `build` commands, you can use our Apple M1 override file that specifies the M1 platform: + +```bash +# in main folder + +# for production +$ docker compose -f docker-compose.yml -f docker-compose.apple-m1.override.yml up + +# for production testing Docker images from DockerHub +$ docker compose -f docker-compose.ocelotsocial-branded.yml -f docker-compose.apple-m1.override.yml up + +# only once: init admin user and create indexes and constraints in Neo4j database +$ docker compose exec backend /bin/sh -c "yarn prod:migrate init" +``` + +## Docker More Closely In Main Code + +To get more informations about the Apple M1 platform and to analyze the Docker builds etc. you find our documentation in our main code, [here](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/DOCKER_MORE_CLOSELY.md). diff --git a/neo4j/README.md b/neo4j/README.md index df3b5fde6..1ea625d89 100644 --- a/neo4j/README.md +++ b/neo4j/README.md @@ -44,7 +44,7 @@ for development, spin up a [hosted Neo4j Sandbox instance](https://neo4j.com/download/), run Neo4j in one of the [many cloud options](https://neo4j.com/developer/guide-cloud-deployment/), [spin up Neo4j in a Docker container](https://neo4j.com/developer/docker/), -on Archlinux you can install [neo4j-community from AUR](https://aur.archlinux.org/packages/neo4j-community/) +on Arch linux you can install [neo4j-community from AUR](https://aur.archlinux.org/packages/neo4j-community/) or on Debian-based systems install [Neo4j from the Debian Repository](http://debian.neo4j.org/). Just be sure to update the Neo4j connection string and credentials accordingly in `backend/.env`. diff --git a/webapp/components/Category/index.vue b/webapp/components/Category/index.vue index 8e4014086..ebbaae584 100644 --- a/webapp/components/Category/index.vue +++ b/webapp/components/Category/index.vue @@ -30,6 +30,7 @@ export default { } } .filterActive { - background-color: $color-success-active; + color: $color-primary-inverse; + background-color: $color-primary-active; } diff --git a/webapp/components/PostTeaser/PostTeaser.vue b/webapp/components/PostTeaser/PostTeaser.vue index 73b721202..7eb5fa87c 100644 --- a/webapp/components/PostTeaser/PostTeaser.vue +++ b/webapp/components/PostTeaser/PostTeaser.vue @@ -26,7 +26,7 @@ v-observe-visibility="(isVisible, entry) => visibilityChanged(isVisible, entry, post.id)" >
-