Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/npm_and_yarn/react-deps-b6b6fabfc0
Browse files Browse the repository at this point in the history
  • Loading branch information
SgtPooki committed Dec 12, 2024
2 parents 66ce5d6 + d72a0a7 commit 9e44fe3
Show file tree
Hide file tree
Showing 19 changed files with 4,452 additions and 4,945 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/deploy-to-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,5 @@ jobs:
with:
tag: ${{ inputs.tag }}
environment: production
lock: true
secrets:
DEPLOYMENT_GITHUB_TOKEN: ${{ secrets.DEPLOYMENT_GITHUB_TOKEN }}
DEPLOYMENT_GITHUB_TOKEN: ${{ secrets.UCI_GITHUB_TOKEN }}
4 changes: 1 addition & 3 deletions .github/workflows/deploy-to-staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,5 @@ jobs:
with:
tag: ${{ inputs.tag }}
environment: staging
lock: true
secrets:
DEPLOYMENT_GITHUB_TOKEN: ${{ secrets.DEPLOYMENT_GITHUB_TOKEN }}

DEPLOYMENT_GITHUB_TOKEN: ${{ secrets.UCI_GITHUB_TOKEN }}
35 changes: 1 addition & 34 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,10 @@ on:
description: 'Environment to deploy to'
required: true
type: string
lock:
description: 'Lock environment branch after deployment'
required: false
type: boolean
default: false
secrets:
DEPLOYMENT_GITHUB_TOKEN:
description: |
A GitHub token with the following permissions:
administration: write (optional; to be able to lock the environment branch)
contents: write (required; to be able to push to the environment branch)
workflows: write (required; to be able to modify .github/workflows)
required: true
Expand All @@ -29,7 +23,7 @@ permissions: {}

jobs:
deploy:
name: Deploy
name: Deploy ${{ inputs.tag }} to ${{ inputs.environment }}
runs-on: ubuntu-latest
environment: ${{ inputs.environment }}
steps:
Expand Down Expand Up @@ -59,34 +53,7 @@ jobs:
env:
TAG: ${{ inputs.tag }}
run: git reset --hard $TAG
# TODO: Use repository rule sets instead of branch protection rules
- name: Unlock environment branch
if: inputs.lock == true
env:
ENVIRONMENT: ${{ inputs.environment }}
GITHUB_TOKEN: ${{ secrets.DEPLOYMENT_GITHUB_TOKEN }}
run: |
gh api --method PUT /repos/$GITHUB_REPOSITORY/branches/$ENVIRONMENT/protection \
-F required_status_checks=null \
-F enforce_admins=true \
-F required_pull_request_reviews=null \
-F restrictions=null \
-F allow_force_pushes=true \
-F lock_branch=false
- name: Force push environment branch
env:
ENVIRONMENT: ${{ inputs.environment }}
run: git push -f origin $ENVIRONMENT
- name: Lock environment branch
if: inputs.lock == true
env:
ENVIRONMENT: ${{ inputs.environment }}
GITHUB_TOKEN: ${{ secrets.DEPLOYMENT_GITHUB_TOKEN }}
run: |
gh api --method PUT /repos/$GITHUB_REPOSITORY/branches/$ENVIRONMENT/protection \
-F required_status_checks=null \
-F enforce_admins=true \
-F required_pull_request_reviews=null \
-F restrictions=null \
-F allow_force_pushes=false \
-F lock_branch=true
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,4 +178,4 @@ jobs:
release-type: node
# Use a token for creating the release-pr and git tags so that the `deploy` workflow can be triggered by them
# see https://github.com/peter-evans/create-pull-request/blob/main/docs/concepts-guidelines.md#triggering-further-workflow-runs and https://github.com/orgs/community/discussions/27028 for more information
token: ${{ secrets.SGTPOOKI_PAT }}
token: ${{ secrets.UCI_GITHUB_TOKEN }}
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
<p align="center">
<a href="https://ipfs.tech"><img src="https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square" alt="Official Part of IPFS Project"></a>
<a href="https://discuss.ipfs.tech"><img alt="Discourse Forum" src="https://img.shields.io/discourse/posts?server=https%3A%2F%2Fdiscuss.ipfs.tech"></a>
<a href="https://matrix.to/#/#ip-js:ipfs.io"><img alt="Matrix" src="https://img.shields.io/matrix/ipfs-space%3Aipfs.io?server_fqdn=matrix.org"></a>
<a href="https://github.com/ipfs/service-worker-gateway/actions"><img src="https://img.shields.io/github/actions/workflow/status/ipfs/service-worker-gateway/main.yml?branch=main" alt="ci"></a>
<a href="https://github.com/ipfs/service-worker-gateway/releases"><img alt="GitHub release" src="https://img.shields.io/github/v/release/ipfs/service-worker-gateway?filter=!*rc*"></a>
</p>
Expand Down Expand Up @@ -39,6 +38,10 @@ happens on end user's machine) and reliability (ability to use multiple sources
of content-addressed blocks) without reliance on a single HTTP server for IPFS
tasks.

<a href="http://ipshipyard.com/"><img align="right" src="https://github.com/user-attachments/assets/39ed3504-bb71-47f6-9bf8-cb9a1698f272" /></a>

This project was brought to you by the [Shipyard](http://ipshipyard.com/) team.


### Goals

Expand Down
Loading

0 comments on commit 9e44fe3

Please sign in to comment.