Hi,
I’m trying to use a secret within my drone.yml. I set it up on the web interface and enabled it for push, tag, deploy and pull request. But it does not seem to be assigned or injected:
pipeline:
test:
image: alpine
environment:
- FOO=bar
- MY_SECRET=${MY_SECRET}
commands:
- echo $FOO
- echo $MY_SECRET
- echo "${MY_SECRET}"
Output:
+ echo $FOO
bar
+ echo $MY_SECRET
+ echo ""
And this is the log output:
droneagent | pipeline: received next execution: 116
gogs | [Macaron] 2017-06-07 11:08:57: Started GET /test/docker-go-test.git/info/refs?service=git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed GET /test/docker-go-test.git/info/refs?service=git-upload-pack 401 Unauthorized in 4.244154ms
gogs | [Macaron] 2017-06-07 11:08:57: Started GET /test/docker-go-test.git/info/refs?service=git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed GET /test/docker-go-test.git/info/refs?service=git-upload-pack 200 OK in 14.44662ms
gogs | [Macaron] 2017-06-07 11:08:57: Started POST /test/docker-go-test.git/git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed POST /test/docker-go-test.git/git-upload-pack 200 OK in 41.233605ms
droneagent | pipeline: finish uploading logs: application/json+logs: step 116: clone
droneagent | pipeline: finish uploading logs: 116: step clone
droneagent | pipeline: finish uploading logs: application/json+logs: step 116: test
droneagent | pipeline: finish uploading logs: 116: step test
droneagent | pipeline: execution complete: 116
droneagent | pipeline: cancel channel closed: 116
droneagent | pipeline: request next execution
droneagent | pipeline: cancel ping loop: 116
droneagent | pipeline: received next execution: 116
gogs | [Macaron] 2017-06-07 11:08:57: Started GET /test/docker-go-test.git/info/refs?service=git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed GET /test/docker-go-test.git/info/refs?service=git-upload-pack 401 Unauthorized in 4.244154ms
gogs | [Macaron] 2017-06-07 11:08:57: Started GET /test/docker-go-test.git/info/refs?service=git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed GET /test/docker-go-test.git/info/refs?service=git-upload-pack 200 OK in 14.44662ms
gogs | [Macaron] 2017-06-07 11:08:57: Started POST /test/docker-go-test.git/git-upload-pack for 172.28.0.1
gogs | [Macaron] 2017-06-07 11:08:57: Completed POST /test/docker-go-test.git/git-upload-pack 200 OK in 41.233605ms
droneagent | pipeline: finish uploading logs: application/json+logs: step 116: clone
droneagent | pipeline: finish uploading logs: 116: step clone
droneagent | pipeline: finish uploading logs: application/json+logs: step 116: test
droneagent | pipeline: finish uploading logs: 116: step test
droneagent | pipeline: execution complete: 116
droneagent | pipeline: cancel channel closed: 116
droneagent | pipeline: request next execution
droneagent | pipeline: cancel ping loop: 116
Screenshot of the secret: https://mb.embe-it.de/media/screenshots/secret.png