Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
f8ad44f
feat: cleanup old files
trash07 Feb 22, 2026
551b3b1
feat: rename files
trash07 Feb 22, 2026
641f3b1
feat: update posts formats
trash07 Feb 22, 2026
258a703
feat: add gatsby files
trash07 Feb 22, 2026
eca3070
feat: prettier, husky
trash07 Feb 23, 2026
424b3ac
feat: install plugins and update pages
trash07 Feb 23, 2026
a01de24
feat: code format
trash07 Feb 23, 2026
3112f69
feat: init github actions
trash07 Feb 23, 2026
395c92a
feat: update actions
trash07 Feb 23, 2026
8462481
feat: update pull request actions
trash07 Feb 23, 2026
031389a
feat: reformat actions
trash07 Feb 23, 2026
98a9302
feat: build static site
trash07 Feb 23, 2026
049d2ac
feat: build static site
trash07 Feb 23, 2026
3317560
fix: add sample file
trash07 Feb 23, 2026
17569d2
feat: add npm cache
trash07 Feb 23, 2026
51a5fd7
feat: setup ansible
trash07 Feb 23, 2026
d7cddec
fix: host key checking
trash07 Feb 23, 2026
4312293
fix: disable host checking
trash07 Feb 23, 2026
7044447
feat: compress and save artifact
trash07 Feb 23, 2026
317fd5e
feat: compress and save artifact
trash07 Feb 23, 2026
144d9d6
feat: compress and save artifact
trash07 Feb 23, 2026
cddd11b
feat: compress and save artifact
trash07 Feb 23, 2026
672efc7
feat: compress and save artifact
trash07 Feb 23, 2026
8e5f010
fix: compress
trash07 Feb 24, 2026
c10e0e5
feat: compress artifact
trash07 Feb 24, 2026
5a01b80
chore: format code
trash07 Feb 24, 2026
e74c952
chore: format code
trash07 Feb 24, 2026
cafed47
chore: format code
trash07 Feb 24, 2026
5dc8450
feat: deploy to preview template
trash07 Feb 24, 2026
791ee29
feat: try environments
trash07 Feb 28, 2026
bc604ce
feat: try prod environment
trash07 Feb 28, 2026
26a5853
feat: add preview environment
trash07 Feb 28, 2026
da3388a
feat: add preview environment
trash07 Feb 28, 2026
546ac83
feat: add deployment templates
trash07 Feb 28, 2026
3c9c917
chore: code format
trash07 Feb 28, 2026
fa6ba61
feat: download artifact
trash07 Feb 28, 2026
cef069d
feat: download artifact
trash07 Feb 28, 2026
9789143
fix: download artifact
trash07 Feb 28, 2026
5dc5599
fix: download artifact
trash07 Feb 28, 2026
52f46e0
fix: download artifact
trash07 Feb 28, 2026
dee4ae1
fix: download artifact
trash07 Feb 28, 2026
1e491cf
fix: download artifact
trash07 Feb 28, 2026
b73b965
fix: download artifact
trash07 Feb 28, 2026
1b5b9e9
fix: download artifact
trash07 Feb 28, 2026
7b2b7c5
fix: download artifact
trash07 Feb 28, 2026
7c9b56d
fix: download artifact
trash07 Feb 28, 2026
9c046fc
fix: download artifact
trash07 Feb 28, 2026
2451c40
fix: download artifact
trash07 Feb 28, 2026
cfd8696
fix: download artifact
trash07 Feb 28, 2026
f6d3994
fix: download artifact
trash07 Feb 28, 2026
e01a84f
fix: download artifact
trash07 Feb 28, 2026
3ddad5f
fix: download artifact
trash07 Feb 28, 2026
869b621
fix: download artifact
trash07 Feb 28, 2026
88cf80d
feat: transfer output for deploy
trash07 Feb 28, 2026
a560412
feat: transfer output for deploy
trash07 Feb 28, 2026
4e5aa0d
feat: transfer output for deploy
trash07 Feb 28, 2026
c61002a
feat: transfer output for deploy
trash07 Feb 28, 2026
db61e72
feat: transfer output for deploy
trash07 Feb 28, 2026
848f2d7
feat: transfer output for deploy
trash07 Feb 28, 2026
faa5513
feat: transfer output for deploy
trash07 Feb 28, 2026
55a4cc5
feat: transfer output for deploy
trash07 Feb 28, 2026
6f3cf71
feat: transfer output for deploy
trash07 Feb 28, 2026
4cf63a6
feat: transfer output for deploy
trash07 Feb 28, 2026
dc9d12c
feat: transfer output for deploy
trash07 Feb 28, 2026
d05397b
feat: transfer output for deploy
trash07 Feb 28, 2026
f14968a
feat: transfer output for deploy
trash07 Feb 28, 2026
bf0e609
feat: transfer output for deploy
trash07 Feb 28, 2026
91f5f72
feat: update docker file
trash07 Mar 1, 2026
1937479
feat: update docker file
trash07 Mar 1, 2026
715eeee
feat: update docker file
trash07 Mar 1, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .env

This file was deleted.

1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@trash07
19 changes: 19 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
## Purpose

Describe the purpose of the pull request and the changes made.

## Related Issues

List any related issues or tickets that this pull request addresses.

## Changes Made

Provide a detailed description of the changes made in this pull request, including any new features, bug

## Change type

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update (changes to documentation only)
- [ ] Security fix (security vulnerability fix)
83 changes: 83 additions & 0 deletions .github/workflows/promote-to-rc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: 2 | Promote to RC
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ vars.NODE_JS_VERSION }}
cache: 'npm'
- name: Build static site
run: |
set -x
npm install
npm run build
- name: Save artifact
env:
REMOTE_FOLDER: '/home/github/dev/artifact/${{ github.repository }}/main'
run: |
set -x
ansible-playbook -i ci/ansible/inventory.ini \
ci/ansible/playbooks/save-artifact.yml \
--extra-vars="ansible_user=${{ secrets.ANSIBLE_USER }} ansible_password=${{ secrets.ANSIBLE_PASS }} current_directory=$(pwd) \
remote_folder=${REMOTE_FOLDER}"

deploy-to-dev:
needs: build
runs-on: ubuntu-latest
environment:
name: dev
url: https://${{ vars.HOST }}
steps:
- name: Login to hub.docker.com
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
- name: Download artifact
env:
REMOTE_FOLDER: '/home/github/dev/artifact/${{ github.repository }}/main'
run: |
sshpass -p "${{ secrets.ANSIBLE_PASS }}" scp -r -o "StrictHostKeyChecking=no" "${{secrets.ANSIBLE_USER}}"@tutoriel.dev:"${REMOTE_FOLDER}/artifact.tar.bz2" .
- name: Extract
run: tar -xjf artifact.tar.bz2
- name: List
run: ls -la
- uses: cschleiden/replace-tokens@v1
with:
files: '["ci/k8s/*.yml"]'
env:
ENV: ${{ vars.ENV }}
HOST: ${{ vars.HOST }}
- name: Check replacements
run: cat ci/k8s/*.yml
- name: Build and compress output
run: |
set -x
mkdir -p output/{k8s,public,nginx}
cp -fr ci/k8s/*.yml output/k8s
cp -fr ci/nginx/*.conf output/nginx
cp -fr public/* output/public
cp -f ci/Dockerfile output/Dockerfile
tar -cjf output.tar.bz2 -C output .
- name: Build and push
uses: docker/build-push-action@v6
with:
context: ./output
push: true
tags: lkpeto/tutoriel.dev:${{ vars.ENV }}
- name: Apply changes
env:
REMOTE_FOLDER: '/home/github/build/${{ github.repository }}/${{ github.run_id }}'
run: |
set -x
ansible-playbook -i ci/ansible/inventory.ini \
ci/ansible/playbooks/deploy-output.yml \
--extra-vars="ansible_user=${{ secrets.ANSIBLE_USER }} ansible_password=${{ secrets.ANSIBLE_PASS }} current_directory=$(pwd) \
remote_folder=${REMOTE_FOLDER}"
58 changes: 58 additions & 0 deletions .github/workflows/publish-changes.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: 3 | Release changes
on:
workflow_dispatch:
jobs:
deploy-to-dev:
runs-on: ubuntu-latest
environment:
name: prod
url: https://${{ vars.HOST }}
steps:
- name: Login to hub.docker.com
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
- name: Download artifact
env:
REMOTE_FOLDER: '/home/github/dev/artifact/${{ github.repository }}/main'
run: |
sshpass -p "${{ secrets.ANSIBLE_PASS }}" scp -r -o "StrictHostKeyChecking=no" "${{secrets.ANSIBLE_USER}}"@tutoriel.dev:"${REMOTE_FOLDER}/artifact.tar.bz2" .
- name: Extract
run: tar -xjf artifact.tar.bz2
- name: List
run: ls -la
- uses: cschleiden/replace-tokens@v1
with:
files: '["ci/k8s/*.yml"]'
env:
ENV: ${{ vars.ENV }}
HOST: ${{ vars.HOST }}
- name: Check replacements
run: cat ci/k8s/*.yml
- name: Build and compress output
run: |
set -x
mkdir -p output/{k8s,public,nginx}
cp -fr ci/k8s/*.yml output/k8s
cp -fr ci/nginx/*.conf output/nginx
cp -fr public/* output/public
cp -f ci/Dockerfile output/Dockerfile
tar -cjf output.tar.bz2 -C output .
- name: Build and push
uses: docker/build-push-action@v6
with:
context: ./output
push: true
tags: lkpeto/tutoriel.dev:${{ vars.ENV }}
- name: Apply changes
env:
REMOTE_FOLDER: '/home/github/build/${{ github.repository }}/${{ github.run_id }}'
run: |
set -x
ansible-playbook -i ci/ansible/inventory.ini \
ci/ansible/playbooks/deploy-output.yml \
--extra-vars="ansible_user=${{ secrets.ANSIBLE_USER }} ansible_password=${{ secrets.ANSIBLE_PASS }} current_directory=$(pwd) \
remote_folder=${REMOTE_FOLDER}"
90 changes: 90 additions & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
name: 1 | Pull request
on:
pull_request:
types:
- opened
- reopened
- synchronize
branches:
- master
- feat/*
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: ${{ vars.NODE_JS_VERSION }}
cache: 'npm'
- name: Build static site
run: |
set -x
npm install
npm run build
- name: Save artifact
env:
REMOTE_FOLDER: '/home/github/dev/artifact/${{ github.repository }}/pull-request'
run: |
set -x
ansible-playbook -i ci/ansible/inventory.ini \
ci/ansible/playbooks/save-artifact.yml \
--extra-vars="ansible_user=${{ secrets.ANSIBLE_USER }} ansible_password=${{ secrets.ANSIBLE_PASS }} current_directory=$(pwd) \
remote_folder=${REMOTE_FOLDER}"

deploy-to-preview:
needs: build
runs-on: ubuntu-latest
environment:
name: preview
url: https://${{ vars.HOST }}
steps:
- name: Login to hub.docker.com
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
- name: Download artifact
env:
REMOTE_FOLDER: '/home/github/dev/artifact/${{ github.repository }}/pull-request'
run: |
sshpass -p "${{ secrets.ANSIBLE_PASS }}" scp -r -o "StrictHostKeyChecking=no" "${{secrets.ANSIBLE_USER}}"@tutoriel.dev:"${REMOTE_FOLDER}/artifact.tar.bz2" .
- name: Extract
run: tar -xjf artifact.tar.bz2
- name: List
run: ls -la
- uses: cschleiden/replace-tokens@v1
with:
files: '["ci/k8s/*.yml"]'
env:
ENV: ${{ vars.ENV }}
HOST: ${{ vars.HOST }}
- name: Check replacements
run: cat ci/k8s/*.yml
- name: Build and compress output
run: |
set -x
mkdir -p output/{k8s,public,nginx}
cp -fr ci/k8s/*.yml output/k8s
cp -fr ci/nginx/*.conf output/nginx
cp -fr public/* output/public
cp -f ci/Dockerfile output/Dockerfile
tar -cjf output.tar.bz2 -C output .
- name: Build and push
uses: docker/build-push-action@v6
with:
context: ./output
push: true
tags: lkpeto/tutoriel.dev:${{ vars.ENV }}
- name: Apply changes
env:
REMOTE_FOLDER: '/home/github/build/${{ github.repository }}/${{ github.run_id }}'
run: |
set -x
ansible-playbook -i ci/ansible/inventory.ini \
ci/ansible/playbooks/deploy-output.yml \
--extra-vars="ansible_user=${{ secrets.ANSIBLE_USER }} ansible_password=${{ secrets.ANSIBLE_PASS }} current_directory=$(pwd) \
remote_folder=${REMOTE_FOLDER}"
10 changes: 4 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
/.idea/
/site/_site/
.jekyll-metadata
/ci/parameters.yml
/site/.jekyll-cache/
/target/
node_modules/
.cache/
public
/.idea/
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npm run format
6 changes: 6 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
node_modules/
.cache/
public
/.idea/
package-lock.json
package.json
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"semi": true,
"singleQuote": true
}
3 changes: 0 additions & 3 deletions Dockerfile

This file was deleted.

84 changes: 48 additions & 36 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,48 @@
# tutoriel.dev
Small hobby blogging website located at [tutoriel.dev](https://tutoriel.dev)

## Installing
To install this repository and contribute, follow these steps:

### Install required software
* [Docker](https://www.docker.com/)
* [Docker Compose](https://docs.docker.com/compose/)
* [Bash](https://www.gnu.org/software/bash/)

### Run start script
```bash
bash scripts.sh start
```

### Wait en enjoy
You need to wait small for all the containers to lunch and start running

### Links
* Use `http://localhost:4000` to develop with live reload
* Use `http://localhost:8080` to see what it will be in prod.

## Other task
To stop the server run the following task
```bash
bash scripts.sh stop
```

## Todos:
- [ ] Simplify the platform UI/UX
- [ ] Write more articles
- [ ] Automate all management tasks

## Credits
* https://github.com/brianmaierjr/long-haul
<p align="center">
<a href="https://www.gatsbyjs.com/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter">
<img alt="Gatsby" src="https://www.gatsbyjs.com/Gatsby-Monogram.svg" width="60" />
</a>
</p>
<h1 align="center">
Gatsby Minimal Starter
</h1>

## 🚀 Quick start

1. **Create a Gatsby site.**

Use the Gatsby CLI to create a new site, specifying the minimal starter.

```shell
# create a new Gatsby site using the minimal starter
npm init gatsby
```

2. **Start developing.**

Navigate into your new site’s directory and start it up.

```shell
cd my-gatsby-site/
npm run develop
```

3. **Open the code and start customizing!**

Your site is now running at http://localhost:8000!

Edit `src/pages/index.jsx` to see your site update in real-time!

4. **Learn more**
- [Documentation](https://www.gatsbyjs.com/docs/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)
- [Tutorials](https://www.gatsbyjs.com/docs/tutorial/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)
- [Guides](https://www.gatsbyjs.com/docs/how-to/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)
- [API Reference](https://www.gatsbyjs.com/docs/api-reference/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)
- [Plugin Library](https://www.gatsbyjs.com/plugins?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)
- [Cheat Sheet](https://www.gatsbyjs.com/docs/cheat-sheet/?utm_source=starter&utm_medium=readme&utm_campaign=minimal-starter)

## 🚀 Quick start (Netlify)

Deploy this starter with one click on [Netlify](https://app.netlify.com/signup):

[<img src="https://www.netlify.com/img/deploy/button.svg" alt="Deploy to Netlify" />](https://app.netlify.com/start/deploy?repository=https://github.com/gatsbyjs/gatsby-starter-minimal)
1 change: 1 addition & 0 deletions assets/images/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# sample file
5 changes: 5 additions & 0 deletions ci/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM nginx:alpine
WORKDIR /usr/share/nginx/html
COPY ./public .
EXPOSE 80
ENTRYPOINT ["nginx", "-g", "daemon off;"]
5 changes: 5 additions & 0 deletions ci/ansible/inventory.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[servers]
tutoriel.dev

[gha]
localhost ansible_connection=local
Loading