2024-05-15 07:22:46 +00:00
|
|
|
name: Jekyll
|
|
|
|
run-name: ${{ gitea.actor }} is running some Gitea Actions 🚀
|
|
|
|
on: [push]
|
|
|
|
|
|
|
|
jobs:
|
2024-05-15 07:44:19 +00:00
|
|
|
test-ci-actions:
|
2024-05-22 10:23:10 +00:00
|
|
|
runs-on: ubuntu-22.04
|
2024-05-15 07:22:46 +00:00
|
|
|
steps:
|
2024-05-15 07:44:19 +00:00
|
|
|
- name: Show event
|
|
|
|
id: event
|
|
|
|
run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
|
|
|
|
- name: Show runner
|
|
|
|
id: runner
|
|
|
|
run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!"
|
|
|
|
- name: Show repository
|
|
|
|
id: repository
|
|
|
|
run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}."
|
2024-05-15 07:22:46 +00:00
|
|
|
- name: Check out repository code
|
2024-05-15 07:44:19 +00:00
|
|
|
id: checkout
|
2024-05-15 07:22:46 +00:00
|
|
|
uses: actions/checkout@v4
|
2024-05-15 07:44:19 +00:00
|
|
|
- name: Show clone completed
|
|
|
|
id: cloned
|
|
|
|
run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
|
|
|
- name: Show readiness
|
|
|
|
id: ready
|
|
|
|
run: echo "🖥️ The workflow is now ready to test your code on the runner."
|
2024-05-15 07:22:46 +00:00
|
|
|
- name: List files in the repository
|
2024-05-15 07:44:19 +00:00
|
|
|
id: list
|
2024-05-15 07:22:46 +00:00
|
|
|
run: |
|
|
|
|
ls ${{ gitea.workspace }}
|
2024-05-15 07:44:19 +00:00
|
|
|
- name: Show status
|
|
|
|
id: status
|
|
|
|
run: echo "🍏 This job's status is ${{ job.status }}."
|
2024-05-15 07:57:11 +00:00
|
|
|
- name: Install docker
|
|
|
|
id: install_docker
|
|
|
|
run: |
|
2024-05-22 11:52:09 +00:00
|
|
|
apt-get -q update
|
|
|
|
apt-get -q install -y docker-compose
|
|
|
|
apt-get -q clean
|
2024-05-15 07:57:11 +00:00
|
|
|
- name: Verify docker
|
2024-05-15 07:44:19 +00:00
|
|
|
id: verify_docker
|
|
|
|
run: |
|
|
|
|
docker run --rm hello-world:latest > /dev/null
|
|
|
|
docker rmi hello-world:latest > /dev/null
|
|
|
|
docker version
|
|
|
|
docker compose version
|
2024-05-22 12:30:15 +00:00
|
|
|
- name: Build Jekyll image
|
|
|
|
id: build_image
|
|
|
|
run: |
|
|
|
|
docker-compose build jekyll
|
|
|
|
-name: Build Jekyll site
|
|
|
|
id: build_site
|
|
|
|
run: |
|
|
|
|
docker-compose run --rm jekyll build --verbose
|