Skip to content

Commit

Permalink
[#2] Add deploy username for gitlab
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMeinerLP committed Feb 13, 2024
1 parent 2a68759 commit e8c495c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
GITLAB_API_URL: ${{ secrets.GITLAB_API_URL }}
GITLAB_PROJECT_ID: ${{ secrets.GITLAB_PROJECT_ID }}
GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }}
GITLAB_USERNAME: ${{ secrets.GITLAB_USERNAME }}
steps:
- name: Checkout Git Repository
uses: actions/checkout@v3
Expand Down
8 changes: 4 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ allprojects {
url = uri("$ciApiv4Url/projects/$projectId/packages/maven")
// See Gradle docs for how to provide credentials to PasswordCredentials
// https://docs.gradle.org/current/samples/sample_publishing_credentials.html
credentials(HttpHeaderCredentials::class) {
name = "Deploy-Token"
value = System.getenv("GITLAB_TOKEN")
credentials(PasswordCredentials::class) {
username = System.getenv("GITLAB_USERNAME")
password = System.getenv("GITLAB_TOKEN")
}
authentication {
create<HttpHeaderAuthentication>("header")
create("basic", BasicAuthentication::class)
}
}
}
Expand Down

0 comments on commit e8c495c

Please sign in to comment.