Testing pipelines
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 9s
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 9s
This commit is contained in:
parent
80ebba33bc
commit
81ff35388b
78
.drone.yml
78
.drone.yml
|
@ -1,78 +0,0 @@
|
||||||
kind: pipeline
|
|
||||||
type: docker
|
|
||||||
name: Tests
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Tests
|
|
||||||
image: docker/compose:1.29.2
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
commands:
|
|
||||||
- docker-compose down -v --remove-orphans -t0
|
|
||||||
- docker-compose build
|
|
||||||
- docker-compose --profile tests build
|
|
||||||
- docker-compose up -d
|
|
||||||
- docker-compose run --rm tests
|
|
||||||
- docker-compose down -v --remove-orphans -t0
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
host:
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
exclude:
|
|
||||||
- tag
|
|
||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
type: docker
|
|
||||||
name: Deploy
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Tests
|
|
||||||
image: docker/compose:1.29.2
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
commands:
|
|
||||||
- docker-compose down -v --remove-orphans -t0
|
|
||||||
- docker-compose build
|
|
||||||
- docker-compose --profile tests build
|
|
||||||
- docker-compose up -d
|
|
||||||
- docker-compose run --rm tests
|
|
||||||
- docker-compose down -v --remove-orphans -t0
|
|
||||||
- name: Build images
|
|
||||||
image: docker/compose:1.29.2
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
commands:
|
|
||||||
- docker build -t lilleman/auth-api-db-migrate:$DRONE_TAG -f ./Dockerfile.migrations .
|
|
||||||
- docker build -t lilleman/auth-api:$DRONE_TAG -f ./Dockerfile .
|
|
||||||
- name: Push to Docker Hub
|
|
||||||
image: docker/compose:1.29.2
|
|
||||||
environment:
|
|
||||||
DOCKERHUB_TOKEN:
|
|
||||||
from_secret: dockerhub
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
commands:
|
|
||||||
- docker login -u lilleman -p $DOCKERHUB_TOKEN
|
|
||||||
- docker push lilleman/auth-api-db-migrate:$DRONE_TAG
|
|
||||||
- docker push lilleman/auth-api:$DRONE_TAG
|
|
||||||
- docker tag lilleman/auth-api-db-migrate:$DRONE_TAG lilleman/auth-api-db-migrate:latest
|
|
||||||
- docker tag lilleman/auth-api:$DRONE_TAG lilleman/auth-api:latest
|
|
||||||
- docker push lilleman/auth-api-db-migrate:latest
|
|
||||||
- docker push lilleman/auth-api:latest
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
- name: docker-sock
|
|
||||||
host:
|
|
||||||
path: /var/run/docker.sock
|
|
||||||
|
|
||||||
trigger:
|
|
||||||
event:
|
|
||||||
- tag
|
|
19
.gitea/workflows/test.yml
Normal file
19
.gitea/workflows/test.yml
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
name: Gitea Actions Demo
|
||||||
|
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
|
||||||
|
on: [push]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
Explore-Gitea-Actions:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
|
||||||
|
- run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!"
|
||||||
|
- run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}."
|
||||||
|
- name: Check out repository code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||||
|
- run: echo "🖥️ The workflow is now ready to test your code on the runner."
|
||||||
|
- name: List files in the repository
|
||||||
|
run: |
|
||||||
|
ls ${{ gitea.workspace }}
|
||||||
|
- run: echo "🍏 This job's status is ${{ job.status }}."
|
Loading…
Reference in New Issue
Block a user