Skip to content

Commit

Permalink
Using multiple docker services
Browse files Browse the repository at this point in the history
  • Loading branch information
LPMendoza committed Sep 6, 2022
1 parent 8c59f03 commit f9b01a6
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 21 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,18 @@ on: push
jobs:
node-docker:
runs-on: ubuntu-latest
container: node:13.5.0-alpine3.10
# container: node:13.5.0-alpine3.10
services:
app:
image: alialaa17/node-api
ports:
- 3001:300
mongo:
image: mongo
ports:
- "27017:27017"
steps:
- name: Log node version
run: |
node -v
cat /etc/os-release
- name: Post a user
run: "curl -X POST http://localhost:3001/api/users -H 'Content-Type: application/json' -d '{\"username\": \"hello\", \"address\": \"asdsad\"}'"
- name: Get Users
run: curl http://localhost:3001/api/users
32 changes: 16 additions & 16 deletions .github/workflows/env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@ jobs:
steps:
- name: Push a random file
run: |
pwd
ls -a
git init
git remote add origin "https://$GITHUB_ACTOR:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY.git"
git config --global user.email "my-bot@bot.com"
git config --global user.name "my-bot"
git fetch
git checkout master
git branch --set-upstream-to=origin/master
git pull
ls -a
echo $RANDOM >> random.txt
ls -a
git add -A
git commit -m "set random file"
git push
# pwd
# ls -a
# git init
# git remote add origin "https://$GITHUB_ACTOR:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY.git"
# git config --global user.email "my-bot@bot.com"
# git config --global user.name "my-bot"
# git fetch
# git checkout master
# git branch --set-upstream-to=origin/master
# git pull
# ls -a
# echo $RANDOM >> random.txt
# ls -a
# git add -A
# git commit -m "set random file"
# git push
- name: Create an issue using REST API
run: |
curl --request POST \
Expand Down

0 comments on commit f9b01a6

Please sign in to comment.