Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/miensoap/extract-env-action
resuable github actions
https://github.com/miensoap/extract-env-action
Last synced: 5 days ago
JSON representation
resuable github actions
- Host: GitHub
- URL: https://github.com/miensoap/extract-env-action
- Owner: Miensoap
- Created: 2024-10-23T11:25:52.000Z (24 days ago)
- Default Branch: main
- Last Pushed: 2024-11-04T12:45:30.000Z (12 days ago)
- Last Synced: 2024-11-04T13:20:29.061Z (12 days ago)
- Language: Shell
- Homepage:
- Size: 4.88 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## export-env-action
GitHub Secret에 여러 환경 변수를 **단 하나의 파일**로 등록해 사용할 수 있습니다.
### 사용 예시
- **Github Secret** : ENV_FILE_CONTENT
```yml
DB_USERNAME=myuser
DB_PASSWORD=mypassword
API_KEY=myapikey
```- test.yml
```yml
jobs:
test:
runs-on: ubuntu-lateststeps:
- name: Set environment variables from secret
uses: Miensoap/[email protected]
with:
env_file_content: ${{ secrets.ENV_FILE_CONTENT }}- name: Use environment variables
run: |
echo "DB_USERNAME is $DB_USERNAME"
```### 테스트 결과
![image](https://github.com/user-attachments/assets/6b1a1419-83ee-483f-a745-f48d35d8dd8d)