.gitea/workflows/services.yml aktualisiert
This commit is contained in:
@@ -3,7 +3,8 @@ on: push
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
# Global Env Variables readable in all jobs of this workflow
|
# Global Env Variables readable in all jobs of this workflow
|
||||||
MONGODB_CLUSTER_ADDRESS: mongodb
|
MONGODB_CLUSTER_ADDRESS: mongodb # The network alias name of the mongodb docker service container
|
||||||
|
# Env Variables which the Example JS App will access
|
||||||
MONGODB_USERNAME: root
|
MONGODB_USERNAME: root
|
||||||
MONGODB_PASSWORD: supersecretpassword
|
MONGODB_PASSWORD: supersecretpassword
|
||||||
MONGODB_DB_NAME: actionsenvironment
|
MONGODB_DB_NAME: actionsenvironment
|
||||||
@@ -11,12 +12,17 @@ env:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
# Job will execute the Steps inside a 'node:latest' docker container
|
||||||
container:
|
container:
|
||||||
image: node:latest
|
image: node:latest
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
services:
|
services:
|
||||||
|
# Before running the Steps of this job...
|
||||||
|
# The runner will spawm a second container 'mongodb' using the mongo:latest image with some db settings
|
||||||
|
# The node container and the mongodb container will be in a new temporary docker bridge network
|
||||||
mongodb:
|
mongodb:
|
||||||
image: mongo:latest
|
image: mongo:latest
|
||||||
|
# Docker related container env Variables for the mongo image (JS App will not have these variables)
|
||||||
env:
|
env:
|
||||||
MONGO_INITDB_DATABASE: actionsenvironment
|
MONGO_INITDB_DATABASE: actionsenvironment
|
||||||
MONGO_INITDB_ROOT_USERNAME: root
|
MONGO_INITDB_ROOT_USERNAME: root
|
||||||
|
|||||||
Reference in New Issue
Block a user