Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sakkyoi/deploy-satro
A template to deploy your site of satro https://github.com/sakkyoi/satro
https://github.com/sakkyoi/deploy-satro
astro cloudflare-pages deployment toturial
Last synced: 26 days ago
JSON representation
A template to deploy your site of satro https://github.com/sakkyoi/satro
- Host: GitHub
- URL: https://github.com/sakkyoi/deploy-satro
- Owner: sakkyoi
- License: lgpl-3.0
- Created: 2024-09-13T08:34:25.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-09-17T07:28:50.000Z (about 2 months ago)
- Last Synced: 2024-09-29T11:45:38.139Z (about 1 month ago)
- Topics: astro, cloudflare-pages, deployment, toturial
- Language: MDX
- Homepage: https://satro-example.pages.dev
- Size: 3.17 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# deploy-satro
## Description
Satro is a ready-to-use static site generator that is built with [Astro](https://astro.build/). This repository is a template that you can use to deploy your site of [satro](https://github.com/sakkyoi/satro) to various platforms.
## Prerequisites
- [Deploy to Cloudflare Pages](./deploy-cloudflare.md)
- [Deploy to GitHub Pages](./deploy-github.md)### Workflow not being run on forked repository
You may have noticed that the workflow isn't being run on your forked repository. This is because of security reasons. You can enable the workflow by just clicking on the `I understand my workflows, go ahead and enable them` button as shown below.
![Workflow aren't being run on this forked repository](./image/github-workflow-arent-being-run-on-this-forked-repository.png)### Workflow dispatch
The workflow files provided in this repository are not triggered by push in default. You can trigger the workflow by using the `workflow_dispatch` event. You can find the `workflow_dispatch` event in the Actions tab of your repository.
![workflow_dispatch event](./image/github-workflow-dispatch-event.png)
Or you can remove the comment from the workflow file to trigger the workflow on push.
```diff
on:
workflow_dispatch:
- # push:
- # branches: [ "main" ]
+ push:
+ branches: [ "main" ]
```## Configure site
Assuming you have already setting up the deploy workflow (including those environment variables starting with `SITE_`) mentioned in the [Prerequisites](#prerequisites) section.
### Announcement
You can create an announcement by creating a file in the `announcement` directory. Head to the [`announcement`](./announcement/) directory to find out more.
### Footer
You can create links or scripts in the footer by creating a file in the `footer` directory. Head to the [`footer`](./footer/) directory to find out more.
The icon attributes are using [Iconify](https://icon-sets.iconify.design/).
> **Note**: External scripts are allowed, for example, please refer to [footer/0_script-jquery.mdx](./footer/0_script-jquery.mdx).
>
> **Additionally**: The order of links and scripts is based on the file name, so you can prefix the file name with a number to set the order (e.g. `0_`, `1_`, `2_`, etc).### Thumbnail, favicon and anything
You can put your thumbnail, favicon, or anything in the [`public`](./public/) directory which will be copied to the root of the site.
> **Note**: You can put your `thumbnail`, `favicon` in several formats simultaneously. But only one file will be used, which is randomly selected in the build process.
### Redirects
Redirects are available if you are deploying to Cloudflare Pages. You can create a file name `_redirects`(in this template, it's already created and will be automatically copied to the `public` directory) and follow the [Redirects](https://developers.cloudflare.com/pages/configuration/redirects/) documentation.
## Start authoring
### Article and image
You can create an article by creating a file in the `article` directory. Head to the [`article`](./article/) directory to find out more.
> **Note**: Path to the image in the article is not relativity, please start with `/` and put the image under the `image` directory. (sub directory is allowed)
### About code block
Code block in the article is using [Expressive Code](https://expressive-code.com/), you can find out more in their documentation.
> **Note**: `pluginCollapsibleSections` plugin is installed by default.
## Next steps
Congratulations! You have successfully completed the setup of your site. You can now start authoring your site, and don't forget to remove the those example files in the `announcement`, `footer`, `public`, and `article` directories.
## Something notable
Details about Astro, please refer to the [Astro documentation](https://docs.astro.build/).
Feel free to forked [satro](https://github.com/sakkyoi/satro) and modify it to suit your needs.
## Demo article
The live demo about how to authoring your content. [Example](https://satro-example.pages.dev/article/example/)
## License
This project is licensed under the LGPLv3 License - see the [LICENSE](./LICENSE) file for details.