mirror of
https://github.com/roles-ansible/ansible_role_gitea.git
synced 2024-08-16 11:39:50 +02:00
Change forgejo repo to code.forgejo.org
This commit is contained in:
parent
b2d64105ae
commit
4115177466
5 changed files with 9 additions and 7 deletions
|
@ -7,7 +7,7 @@
|
||||||
|
|
||||||
This role installs and manages [gitea](https://gitea.io) or [forgejo](https://forgejo.org). A painless self-hosted Git service. Gitea is a community managed lightweight code hosting solution written in Go. Forgejo is a fork of it.
|
This role installs and manages [gitea](https://gitea.io) or [forgejo](https://forgejo.org). A painless self-hosted Git service. Gitea is a community managed lightweight code hosting solution written in Go. Forgejo is a fork of it.
|
||||||
[Source code & screenshots gitea](https://github.com/go-gitea/gitea).
|
[Source code & screenshots gitea](https://github.com/go-gitea/gitea).
|
||||||
[Source code forgejo](https://codeberg.org/forgejo/forgejo).
|
[Source code forgejo](https://code.forgejo.org/forgejo/forgejo).
|
||||||
This role is also Part of the Ansible-Collection [l3d.git](https://galaxy.ansible.com/l3d/git). [![l3d.git](https://ansible.l3d.space/svg/l3d.git_ansible-collection_collection.svg)](https://github.com/roles-ansible/ansible_collection_git.git).
|
This role is also Part of the Ansible-Collection [l3d.git](https://galaxy.ansible.com/l3d/git). [![l3d.git](https://ansible.l3d.space/svg/l3d.git_ansible-collection_collection.svg)](https://github.com/roles-ansible/ansible_collection_git.git).
|
||||||
|
|
||||||
## Mirrors
|
## Mirrors
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
block:
|
block:
|
||||||
- name: "Get latest forgejo release metadata"
|
- name: "Get latest forgejo release metadata"
|
||||||
ansible.builtin.uri:
|
ansible.builtin.uri:
|
||||||
url: 'https://codeberg.org/api/v1/repos/forgejo/forgejo/releases?limit=1'
|
url: 'https://{{ gitea_forgejo_repo }}/api/v1/repos/forgejo/forgejo/releases?limit=1'
|
||||||
return_content: true
|
return_content: true
|
||||||
register: gitea_forgejo_remote_metadata
|
register: gitea_forgejo_remote_metadata
|
||||||
become: false
|
become: false
|
||||||
|
@ -45,12 +45,12 @@
|
||||||
block:
|
block:
|
||||||
- name: "Get specific forgejo release metadata"
|
- name: "Get specific forgejo release metadata"
|
||||||
ansible.builtin.uri:
|
ansible.builtin.uri:
|
||||||
url: 'https://codeberg.org/api/v1/repos/forgejo/forgejo/releases/tags/v{{ gitea_version_target }}'
|
url: 'https://{{ gitea_forgejo_repo }}/api/v1/repos/forgejo/forgejo/releases/tags/v{{ gitea_version_target }}'
|
||||||
return_content: true
|
return_content: true
|
||||||
register: gitea_forgejo_remote_tags_metadata
|
register: gitea_forgejo_remote_tags_metadata
|
||||||
become: false
|
become: false
|
||||||
rescue:
|
rescue:
|
||||||
- name: "Error Downloading https://codeberg.org/api/v1/repos/forgejo/forgejo/releases/tags/v{{ gitea_version_target }}"
|
- name: "Error Downloading https://{{ gitea_forgejo_repo }}/api/v1/repos/forgejo/forgejo/releases/tags/v{{ gitea_version_target }}"
|
||||||
ansible.builtin.fail:
|
ansible.builtin.fail:
|
||||||
msg: "We did not find the forgejo version you specified. Are you sure that '{{ gitea_version_target }}' is a valid forgejo version?"
|
msg: "We did not find the forgejo version you specified. Are you sure that '{{ gitea_version_target }}' is a valid forgejo version?"
|
||||||
|
|
||||||
|
@ -84,7 +84,7 @@
|
||||||
|
|
||||||
- name: "Set a example forgejo download link if in check mode"
|
- name: "Set a example forgejo download link if in check mode"
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
gitea_forgejo_dl_url: ['https://codeberg.org/attachments/a00333ad-250a-4d30-a764-9a37fb24f419']
|
gitea_forgejo_dl_url: ['https://{{ gitea_forgejo_repo }}/attachments/a00333ad-250a-4d30-a764-9a37fb24f419']
|
||||||
when: ansible_check_mode
|
when: ansible_check_mode
|
||||||
|
|
||||||
- name: "Set a example forgejo checksum link if in check mode"
|
- name: "Set a example forgejo checksum link if in check mode"
|
||||||
|
@ -94,7 +94,7 @@
|
||||||
|
|
||||||
- name: "Set a example forgejo checksum link if in check mode"
|
- name: "Set a example forgejo checksum link if in check mode"
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
gitea_forgejo_signed_url: ['https://codeberg.org/attachments/ae5e50c6-e86e-4202-b95f-f142e8138e2f']
|
gitea_forgejo_signed_url: ['https://{{ gitea_forgejo_repo }}/attachments/ae5e50c6-e86e-4202-b95f-f142e8138e2f']
|
||||||
when: ansible_check_mode
|
when: ansible_check_mode
|
||||||
|
|
||||||
- name: 'Assert that remote version is higher'
|
- name: 'Assert that remote version is higher'
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
{{ ansible_managed | comment }}
|
||||||
[Unit]
|
[Unit]
|
||||||
Description={{ gitea_fork }} git server
|
Description={{ gitea_fork }} git server
|
||||||
After=network.target
|
After=network.target
|
||||||
|
|
|
@ -5,3 +5,4 @@ gitea_filename: "forgejo-{{ gitea_version_target }}-linux-{{ gitea_arch }}"
|
||||||
gitea_forgejo_query_download: "assets[?name==`{{ gitea_filename }}`].browser_download_url"
|
gitea_forgejo_query_download: "assets[?name==`{{ gitea_filename }}`].browser_download_url"
|
||||||
gitea_forgejo_query_checksum: "assets[?name==`{{ gitea_filename }}.sha256`].browser_download_url"
|
gitea_forgejo_query_checksum: "assets[?name==`{{ gitea_filename }}.sha256`].browser_download_url"
|
||||||
gitea_forgejo_query_signed: "assets[?name==`{{ gitea_filename }}.asc`].browser_download_url"
|
gitea_forgejo_query_signed: "assets[?name==`{{ gitea_filename }}.asc`].browser_download_url"
|
||||||
|
gitea_forgejo_repo: 'code.forgejo.org'
|
||||||
|
|
|
@ -63,5 +63,5 @@ transfer_custom_footer:
|
||||||
- 'files/gitea_footer/extra_links_footer.tmpl'
|
- 'files/gitea_footer/extra_links_footer.tmpl'
|
||||||
- 'files/extra_links_footer.tmpl'
|
- 'files/extra_links_footer.tmpl'
|
||||||
|
|
||||||
playbook_version_number: 56
|
playbook_version_number: 57
|
||||||
playbook_version_path: 'do1jlr.gitea.version'
|
playbook_version_path: 'do1jlr.gitea.version'
|
||||||
|
|
Loading…
Reference in a new issue