docker.#Run now use secrets from dagger.#Secret

Signed-off-by: Tom Chauveau <tom.chauveau@epitech.eu>
This commit is contained in:
Tom Chauveau 2021-06-03 13:59:22 +02:00
parent ca03cd6e58
commit a39e87b179
18 changed files with 123 additions and 151 deletions

View File

@ -52,13 +52,13 @@ import (
port: *22 | int @dagger(input) port: *22 | int @dagger(input)
// Ssh private key // Ssh private key
key: dagger.#Artifact @dagger(input) key: dagger.#Secret @dagger(input)
// User fingerprint // User fingerprint
fingerprint?: string @dagger(input) fingerprint?: string @dagger(input)
// Ssh passphrase // Ssh passphrase
passphrase?: string @dagger(input) passphrase?: dagger.#Secret @dagger(input)
// Image reference (e.g: nginx:alpine) // Image reference (e.g: nginx:alpine)
ref: string @dagger(input) ref: string @dagger(input)
@ -114,24 +114,10 @@ import (
#up: [ #up: [
op.#Load & {from: #Client}, op.#Load & {from: #Client},
op.#WriteFile & {
content: key
dest: "/key"
mode: 0o400
},
if registry != _|_ { if registry != _|_ {
op.#DockerLogin & {registry} op.#DockerLogin & {registry}
}, },
if passphrase != _|_ {
op.#WriteFile & {
content: passphrase
dest: "/passphrase"
mode: 0o400
}
},
if passphrase != _|_ { if passphrase != _|_ {
op.#WriteFile & { op.#WriteFile & {
content: #""" content: #"""
@ -172,6 +158,12 @@ import (
FINGERPRINT: fingerprint FINGERPRINT: fingerprint
} }
} }
mount: {
"/key": secret: key
if passphrase != _|_ {
"/passphrase": secret: passphrase
}
}
}, },
] ]
} }

View File

@ -77,21 +77,17 @@ setup() {
} }
@test "stdlib: docker: run" { @test "stdlib: docker: run" {
skip_unless_secrets_available "$TESTDIR"/stdlib/docker/run/key.yaml
# Simple run # Simple run
run "$DAGGER" compute --input-yaml "$TESTDIR"/stdlib/docker/run/key.yaml "$TESTDIR"/stdlib/docker/run/simple/ run "$DAGGER" up -w "$TESTDIR"/stdlib/docker/run/simple/
assert_success assert_success
# Handle key with passphrase # Protected ssh key
skip_unless_secrets_available "$TESTDIR"/stdlib/docker/run/protected-key.yaml run "$DAGGER" up -w "$TESTDIR"/stdlib/docker/run/passphrase/
assert_success
# Fail if invalid password # Protected ssh key with wrong passphrase
run "$DAGGER" compute --input-yaml "$TESTDIR"/stdlib/docker/run/protected-key.yaml "$TESTDIR"/stdlib/docker/run/wrrong-passphrase/ run "$DAGGER" up -w "$TESTDIR"/stdlib/docker/run/wrong-passphrase/
assert_failure assert_failure
run "$DAGGER" compute --input-yaml "$TESTDIR"/stdlib/docker/run/protected-key.yaml "$TESTDIR"/stdlib/docker/run/passphrase/
assert_success
} }
@test "stdlib: terraform" { @test "stdlib: terraform" {

View File

@ -1,34 +0,0 @@
registry:
username: ENC[AES256_GCM,data:8AH6p9WHidanCA==,iv:ezThCQJv+bVBf8SdfSa2HFoP+eu6IZMPl5xvMOGDcps=,tag:mzR7xTKeQNDvkyd2Dm3AKw==,type:str]
secret: ENC[AES256_GCM,data:GtuaBAhFBw2JFaeuOm6mUr3m1j5fvCJjcWAzjsdU2xASFxwO,iv:YAXcRzBoemmef5PBdAOBa5acNPo4BoKH7Ngud/CWYfA=,tag:MCCUCOSutjRCI92raYrxdg==,type:str]
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
age: []
lastmodified: "2021-04-27T00:59:33Z"
mac: ENC[AES256_GCM,data:qk+oo4m5OpfuQ+R3pZUuvn+gqAk15OAJzOULrlYqt1FIDRk/Q5ah5QpIbVxeP1EDVyuY/V/E0ZngRlSV7Dyx6Cp/moMd8AFBHNgnTB+Lq+NmZ9HR1QMOxpbMpJmUGn7MqQ1Ys4wy0p2q2Y2+TuUpKwmRGJbGVYEVmqvV5OT3jhc=,iv:QsUFa2GVzy6iqqLXRz8HascQZPIIzKBhxHdlabov02k=,tag:7lk63FeXsOlTCgfmWd7zrg==,type:str]
pgp:
- created_at: "2021-03-18T22:59:59Z"
enc: |
-----BEGIN PGP MESSAGE-----
hQIMAzqVY590vudzAQ//etnfnpfCo9rAkctR+Fwg/7VdVL3Rov+6gnyjUnoN1BS1
8jnBF/86AZ7uK89dTcTZCsK1hKPxeYg1kJTKpA+zfDORupzTWcMrRyjwNk5wQ2Vg
N1adUwFsBQpk8WptpsU/ro6+3yH+Nn35begs6hP2fH/EQ9XOxw5gY0kp0AFjGaKJ
tRZVrr3f2hpLESo6LILRO97UXZiGcwTn5onslECL92260cU1nqEQp+ESK7XrdYIG
99oM3eXEraKw4WuQDaDE6U135aUl6vIJWD1JZzyr3RW3+5O9pn5rpN3Wc0TbDR6+
9Fs/TjuA1h5eJzbt+lkA74BtxPOBv9O7HJnWJpXjiG0VUGHdFXoq5Tr5Ol68RQxa
BWe7IfTO6FHN0xOl1dY7cn5jtf+xlFjL86s9OkrJUFa9lbQx8L/QPCeA2Xiu4tpW
+wTSel13k8Uv/JSGgLwSohW6N4XTQYdxPkO+a1V08adwFBXaGgqxfg0rNehcS5fp
y3TEq84cOlBsaI+rYpnOTPEajtYWfTe8WFf+lBOn1vZ9EiupjZtefGX2MIWPXoaK
kVBgRvzjp4/BY68yRvdi5sZFd2nakl+DOXzouuFbzsOkxL3o9FA9aCVsXtFqqzSG
Hvq4ZJ5ivXf6vQf+s7Tgc4qxW2CQwIPZVkHhQossrWgtkQ4WDAyzfhF0YuhEnpLS
XgGNLr82LMVmempaJd7GfAR2nwGnLUTYny1KoiW/1ie6DPwLZBX/UxPOplaS5wYH
Xd3gV3smg5xZ7/rfvzKTzJ1a5yH6D3xI05UtnUWdqojONcXS9NS+P7RArngJwSs=
=m0OS
-----END PGP MESSAGE-----
fp: 6CB37404020B5F0A0B41B5BB225EBAB0B936AC65
unencrypted_suffix: _unencrypted
version: 3.7.1

View File

@ -1,33 +0,0 @@
key: ENC[AES256_GCM,data:WVwwHYqXbaMtZu3bMbNrwhexIsfUHRaocq+6yvS55I+9BI2T9X2xvFz7IiMC+1gY9tcVkq4Fs0/bIOjDpjQ14GPNxxnbhtzyp7nFI7EnrSWCwRnHjmc+2fMcpdRFRDaYvZt+aHA9x874nCOT5DQLniKTwi8WAKMcKVuMg6g+gHVXtrFEG0d+1pJuypRannXgOlt2TgpNO9VhZFFivJbJ5fATX0xMuctBEV6CVR2gBqx62Zqz1C/znDv+BiEYHntFeXntb/n0gIL2gmTAcQbBMC5e0i8LmqmZkbCgs3GwiImNEnjaSQf97DsrfzSOEAPpz0hCo7EIF9gQHimNads/WYDvSvvH4MD1ReLBtQD22jO3JFxFrTyimAKKd0IqdMsh+S2ZqxeG8tt2yq0dEYWUdVxPpr5fgmlsfHuBE+qbPE+s2QvWvgFo3ZIaxvcKe1NSVLrNh2u666uUJK2/wetzLllYomkqvqmJxUtJHtyQg+cDOErKomFXXbeSoMw9/xnTpR5oHj7icAqehYilAm71cKWA1qpuUtbhYe8Z,iv:b3AG6AWe/Rw26R1ZPHvTGoONpjQMdf/OWLoazyySRig=,tag:lv413iPTOejZwPdUDGUsAw==,type:str]
passphrase: ENC[AES256_GCM,data:6yw78pBY2B4=,iv:vdBWBE02qSyGmqyDeSM/4DP1QhKKFn9D1bCdP+oKic4=,tag:cg/WzydFf+IXflxW7v0BRA==,type:str]
user: ENC[AES256_GCM,data:L3sBCudP5iA=,iv:gupZZbW9kMxC+LpAV6+S2TankSnRTbCg87Rq10U50bo=,tag:0uPJtM0qrQkq+3p7yQOmKA==,type:str]
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
lastmodified: '2021-05-28T15:55:50Z'
mac: ENC[AES256_GCM,data:ZRHdrBWlnjy/AMpl2X9jInUMZdSbvdWYQTRKItNAU2gjz3baCJtGdbFb4hE7bwFPxkuv4EvzongTmUmzs9dBlmZhDIwbqeo54C37Purbi6q1CLE2wSYPdSxpP6LkJDbM4QBQ0smX3jf12K4UqPmI3e46YJtEDgtS5pNPrSGXBn0=,iv:ycQ4add4ih0nuQxBCbe5fsvMfBizX/mA7eWKBn3azBE=,tag:dF7PfbJKxMOiTBKH5VJJQA==,type:str]
pgp:
- created_at: '2021-03-18T22:59:59Z'
enc: |
-----BEGIN PGP MESSAGE-----
hQIMAzqVY590vudzAQ//etnfnpfCo9rAkctR+Fwg/7VdVL3Rov+6gnyjUnoN1BS1
8jnBF/86AZ7uK89dTcTZCsK1hKPxeYg1kJTKpA+zfDORupzTWcMrRyjwNk5wQ2Vg
N1adUwFsBQpk8WptpsU/ro6+3yH+Nn35begs6hP2fH/EQ9XOxw5gY0kp0AFjGaKJ
tRZVrr3f2hpLESo6LILRO97UXZiGcwTn5onslECL92260cU1nqEQp+ESK7XrdYIG
99oM3eXEraKw4WuQDaDE6U135aUl6vIJWD1JZzyr3RW3+5O9pn5rpN3Wc0TbDR6+
9Fs/TjuA1h5eJzbt+lkA74BtxPOBv9O7HJnWJpXjiG0VUGHdFXoq5Tr5Ol68RQxa
BWe7IfTO6FHN0xOl1dY7cn5jtf+xlFjL86s9OkrJUFa9lbQx8L/QPCeA2Xiu4tpW
+wTSel13k8Uv/JSGgLwSohW6N4XTQYdxPkO+a1V08adwFBXaGgqxfg0rNehcS5fp
y3TEq84cOlBsaI+rYpnOTPEajtYWfTe8WFf+lBOn1vZ9EiupjZtefGX2MIWPXoaK
kVBgRvzjp4/BY68yRvdi5sZFd2nakl+DOXzouuFbzsOkxL3o9FA9aCVsXtFqqzSG
Hvq4ZJ5ivXf6vQf+s7Tgc4qxW2CQwIPZVkHhQossrWgtkQ4WDAyzfhF0YuhEnpLS
XgGNLr82LMVmempaJd7GfAR2nwGnLUTYny1KoiW/1ie6DPwLZBX/UxPOplaS5wYH
Xd3gV3smg5xZ7/rfvzKTzJ1a5yH6D3xI05UtnUWdqojONcXS9NS+P7RArngJwSs=
=m0OS
-----END PGP MESSAGE-----
fp: 6CB37404020B5F0A0B41B5BB225EBAB0B936AC65
unencrypted_suffix: _unencrypted
version: 3.7.1

View File

@ -0,0 +1,2 @@
# dagger state
state/**

View File

@ -0,0 +1,19 @@
package docker
import (
"dagger.io/docker"
"dagger.io/dagger"
)
key: dagger.#Secret @dagger(input)
passphrase: dagger.#Secret @dagger(input)
user: string @dagger(input)
TestRun: run: docker.#Run & {
host: "143.198.64.230"
ref: "nginx:alpine"
"user": user
"passphrase": passphrase
name: "daggerci-test-simple-\(random)"
"key": key
}

View File

@ -0,0 +1,28 @@
name: default
inputs:
key:
secret: ENC[AES256_GCM,data:OCiRUAarKcn5fK3jcAhV9xRS4AmpaXth6Bu8ozQ0dknyeM1ech2gzWMRfnBM1lIfcIxKAD/Dm7V4yJcj0sfGbgEsvpAslal6DYQ47lHDiGmDGDzu3dWAOqJpXwCCgsMagC/PoccsJPN4It0LyBW34dgBTB9NYC4fCX7ZpobLsw9Uf/JMAsxHp/nrUVhYDqHv2RXTV4zmdNIHjam+yFQLvSsSYdUOsEjx5DNMxmGM6Q9WuveqfM4sreetondvVzCVHBBB21dMO4WzJ2TwonobYvoSXxIVP/pHh0W3EIO46jLTvTv4NFAoyalFqTCf4ROPpsnFhCqLn10Iya1jn9h3QOrdsvA263zwv13bByPk+zOPRMJKfMN+VJMuKaT2a5zMVdhx35ULu9lEF6Xci7L1NEKIeRIfkyPHO5gSIdLVFGquU0qAasJ9rl7GDeTwyC9ejTJxOhbvPtmkq3ASFPkk7nC92IpOfjNVa3Y+hxxdmKKKJciSFcENGH0FvgbZo6gXft2dPpSiuwhbaxT42zJheOsLbTlgqzhJA8cHeT15kaOZNj/q0IkQStzo5P88EPdghNnEqq15szlKNS88gxbMIVuFpSFHDySBTHwOXXSmwrs=,iv:jNa+Pm4nOqAoQwa4b1auGvSYVPxNH3MQEagF5BKyyEs=,tag:vx8IUtpi9utnkzKSn/WTQw==,type:str]
passphrase:
secret: ENC[AES256_GCM,data:2pmIFddxYG8=,iv:Oty+wFlDEfzYcfXaJrhr6OOANP6o9gdD7fU0njEHloI=,tag:Ht4FJ0IZzQYazNcj1K0miw==,type:str]
user:
text: daggerci
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
age:
- recipient: age1gxwmtwahzwdmrskhf90ppwlnze30lgpm056kuesrxzeuyclrwvpsupwtpk
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBXV3E3c3h4R0xKcnB5YUo5
eUdkeTZUbjZ4SU9VOTdEVzVPL296ZzRQMVNZCkMxblZKTXE0TDdhdy9PVk1sQ015
VWxxNjlLc2RMdUxFV3FrbVJMYk9KRzQKLS0tIHNGeXIvY3M5MTNHM05XTmNESkpZ
ZXAwa1h2aEhGRGpwVTJzKy9EZGhQb0kKSYnRAiRh7b2LViajHk46ct94PVLHDajC
oaUPwzy4bIMI9UXGobkstC5ObmY3ba+jcPRy6c9moniL+iigZ8YglA==
-----END AGE ENCRYPTED FILE-----
lastmodified: "2021-06-03T11:33:27Z"
mac: ENC[AES256_GCM,data:r3ngidgRewF0HqD3jI0PXeLTBsWw2HmDc1RP0Gtvo+vvgMqVbQEM/5Y/oI3tKDOqpS7iPXC49AHnNAO/NouYk4grebz/Tksn4OjDmwE/TzRV/EmRnC6LrT3/Fwga6NlG4QkxdWop9i7Wc+ND3BoCTVnWYB3Zr8zwOMcQaiUOdjI=,iv:KSYagnxOYKwIYEZzkP61O+rO/u4q61duTUFUy1vARpw=,tag:vxvioVzcIgVRtqLBHGvMfA==,type:str]
pgp: []
encrypted_suffix: secret
version: 3.7.1

View File

@ -1,33 +0,0 @@
key: ENC[AES256_GCM,data:YrLeVqoLuzcEIK6FYCGiP9DhuMAlYU3o9UX6VcensCVAA9+Ix2Y7asBp1iqRpvHLEpT8AYe7Hb+PLuyvRjyY2dKW86BecxBUyX39rc5WWB5CK8nS1jR7qdRljcJca9Pw1jKiPmSht5wtVkJQtVORsHNVQipzj6ouGVBqkw0gPPvp9Ywfrgxw+sOhdkU7FrjmoAZygQ2fbTQM7q6QhpLh1MWXw532eoIRarrxO29T6/CPl5Z17jSd9OIlKVV4iwqWrzovU857oqd9MpU+aj/dVubq497/krnStNeWnUkHyJp+IwX0hO1T5E6uj08prXw8wSTWpdtsfTChfKNDvAgshTmHN8g0bw0qmbUmdDxBSUFRUI95iOJSPLxStIobajK5W1foHbEqgiTm2Ki6ugkBaOL7v+wNhlkFXOfZrbKDBz9CCndFyzig+wXAGT+MovgwgF1S7m1av/8TGkpmxCuUPjfEmNttrwy8xACH/A/WxMoOQhFZ4Q2LUTQdtptvi32WudUMmUZdcI+VJ9TgQVSng1mPOx7yCDgIeym9vKTqZ2DHLgkKtmO+xpZfQHaifcRolJGYINatZPPYQs7kIunwPQH7pZazld45z6Lt7xXQ9/8=,iv:ac0ij8s482TzLHxNTkbr/i5O9t5NL8IMzdQS6rfmwRQ=,tag:Mew5sRiCTDavwD7GKZK/qw==,type:str]
passphrase: ENC[AES256_GCM,data:6yw78pBY2B4=,iv:vdBWBE02qSyGmqyDeSM/4DP1QhKKFn9D1bCdP+oKic4=,tag:cg/WzydFf+IXflxW7v0BRA==,type:str]
user: ENC[AES256_GCM,data:L3sBCudP5iA=,iv:gupZZbW9kMxC+LpAV6+S2TankSnRTbCg87Rq10U50bo=,tag:0uPJtM0qrQkq+3p7yQOmKA==,type:str]
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
lastmodified: '2021-05-28T16:13:38Z'
mac: ENC[AES256_GCM,data:v4aC/yw20M2GnIktqxoGJCD4T4ViBivzMsBawNgBLTytRGI7s+QGEzdmfoF+dqA3Vdkzf0WKmoiUQ2bcbTjMx2sqvAiiavUz2/iOKdALpn2f13PHeJDBB8A9rnIdidhNadWm6rICIdlxuSmx3tCGIHcM7BY0XJvK3cr6q/3b+jE=,iv:j0J0gwpOGcDtItloYo1mbjfGJloioM1IanjqKwnOIA8=,tag:qPciC7z1fF3mNl+Zx7Fx4A==,type:str]
pgp:
- created_at: '2021-03-18T22:59:59Z'
enc: |
-----BEGIN PGP MESSAGE-----
hQIMAzqVY590vudzAQ//etnfnpfCo9rAkctR+Fwg/7VdVL3Rov+6gnyjUnoN1BS1
8jnBF/86AZ7uK89dTcTZCsK1hKPxeYg1kJTKpA+zfDORupzTWcMrRyjwNk5wQ2Vg
N1adUwFsBQpk8WptpsU/ro6+3yH+Nn35begs6hP2fH/EQ9XOxw5gY0kp0AFjGaKJ
tRZVrr3f2hpLESo6LILRO97UXZiGcwTn5onslECL92260cU1nqEQp+ESK7XrdYIG
99oM3eXEraKw4WuQDaDE6U135aUl6vIJWD1JZzyr3RW3+5O9pn5rpN3Wc0TbDR6+
9Fs/TjuA1h5eJzbt+lkA74BtxPOBv9O7HJnWJpXjiG0VUGHdFXoq5Tr5Ol68RQxa
BWe7IfTO6FHN0xOl1dY7cn5jtf+xlFjL86s9OkrJUFa9lbQx8L/QPCeA2Xiu4tpW
+wTSel13k8Uv/JSGgLwSohW6N4XTQYdxPkO+a1V08adwFBXaGgqxfg0rNehcS5fp
y3TEq84cOlBsaI+rYpnOTPEajtYWfTe8WFf+lBOn1vZ9EiupjZtefGX2MIWPXoaK
kVBgRvzjp4/BY68yRvdi5sZFd2nakl+DOXzouuFbzsOkxL3o9FA9aCVsXtFqqzSG
Hvq4ZJ5ivXf6vQf+s7Tgc4qxW2CQwIPZVkHhQossrWgtkQ4WDAyzfhF0YuhEnpLS
XgGNLr82LMVmempaJd7GfAR2nwGnLUTYny1KoiW/1ie6DPwLZBX/UxPOplaS5wYH
Xd3gV3smg5xZ7/rfvzKTzJ1a5yH6D3xI05UtnUWdqojONcXS9NS+P7RArngJwSs=
=m0OS
-----END PGP MESSAGE-----
fp: 6CB37404020B5F0A0B41B5BB225EBAB0B936AC65
unencrypted_suffix: _unencrypted
version: 3.7.1

View File

@ -0,0 +1,2 @@
# dagger state
state/**

View File

@ -5,8 +5,7 @@ import (
"dagger.io/dagger" "dagger.io/dagger"
) )
// Run with --input-file key=$HOME/.ssh/<your private server key> key: dagger.#Secret @dagger(input)
key: dagger.#Artifact
TestRun: run: docker.#Run & { TestRun: run: docker.#Run & {
host: "143.198.64.230" host: "143.198.64.230"

View File

@ -0,0 +1,24 @@
name: default
inputs:
key:
secret: ENC[AES256_GCM,data:LdStiF5uyUW82+PE0pH2FxY9REawCC12KkmzP4tg8+GY64AIjoxMERTphmCE/wviTYTRQmzY3UniTd63cEVZ40FhiC+bUr1OnYfLmD/eaU2Sq2dfDdr1B11Vi1tFiq1Bm/InM05OpbUhwVeTGWFmOUuSYJAVcWwAV40nH/nxHg5KJQnPlmIxbmo4xtTkjE8yBgh5YsQy6A1oRap1wq+1GSJDYKDF/4f1C+7KtuNYhz82E+7L9O+OE356pWrVE1ocq4wh9uMIfswKDC1yIz5zdxU+VMfFAqqxLwMpZGJDIaZv5V1PEq7kgfK5xha7N0X3ek6woADd01rrYBTXbTov0Zce4GLXshaLKXDsWgFO75td7dRcH44+mKj9FFJCcBfVzID90fH80Q0JaZTNoZp0EJmLmIZ4p/D9OfziCL+MlMfHJCiK4i69wHxiZWBL7N918fMzr2SJaSqUEyWCZfvytjqzNKH4PGG0k/tO+KUDzDTVwpXU57RCvJU8imp4OpLoevjwEfjZ/i1IjDM+YjuVyHrffCpq1mX1OwkD,iv:A+8vdkhdye6bJfI+QMNOvCDproRsCO6m1CA1I1J9jlg=,tag:ujDkawZMuBfv9FEsKYnJZw==,type:str]
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
age:
- recipient: age1gxwmtwahzwdmrskhf90ppwlnze30lgpm056kuesrxzeuyclrwvpsupwtpk
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBpamtuNHB6NjY5L3VNT3hl
TGlmVFFoZURJR1RmZEFvSGUyVFRaSWNnSUMwClJiaDVGZWJoeDBMY21jZTVlREdS
aWg0SjNWN3BrTXRneXJyZy80K1JRSFUKLS0tIFEwKzdkVkNPT2VHTmtiOEdDQlZa
cnh2eHU5TzFjVkNvTzUyczFBL0pwTDQK60+wrLmTaD3Ws5ZAXdqBkMjaVP7Iz69k
UrkqkMbaUlvvSKK7dB5MuTGEEN6A1viAGal9ZjDHlSobkNPuE24QEA==
-----END AGE ENCRYPTED FILE-----
lastmodified: "2021-06-03T10:42:54Z"
mac: ENC[AES256_GCM,data:KU9f8Pa1hP7E59lmdt4tEIL4XJ+wMFbA8zHc/pzKXYiW9ryL94rDiFOzpcVcEtrSTEYl7J9ObnF0aGISWIMwlctOyBYpTOTz1ornzgdQaQn+ETGclcpi9pDtKWRSd7CQ4NmvbL51FUR0WmDDfBqIIjIg3RBwcWGZBTUCEy6aJjo=,iv:ZfZAedZWylLLvh+7Kka/ceb8XzQ+V/XkmPYKvAc6hHY=,tag:ymzo+Tb9M64BBJQSTNZXVA==,type:str]
pgp: []
encrypted_suffix: secret
version: 3.7.1

View File

@ -0,0 +1,2 @@
# dagger state
state/**

View File

@ -6,9 +6,9 @@ import (
) )
// Run with --input-file key=$HOME/.ssh/<your private server key> // Run with --input-file key=$HOME/.ssh/<your private server key>
key: dagger.#Artifact key: dagger.#Secret @dagger(input)
passphrase: dagger.#Secret passphrase: dagger.#Secret @dagger(input)
user: dagger.#Secret user: string @dagger(input)
TestRun: run: docker.#Run & { TestRun: run: docker.#Run & {
host: "143.198.64.230" host: "143.198.64.230"

View File

@ -0,0 +1,28 @@
name: default
inputs:
key:
secret: ENC[AES256_GCM,data:YbMbZupCsh3LmLK3SmQ9xSnTTC36jtt0GcM5a25222KCLYPIDmrratE/4TpklMBgr/dcCrWQIT7SsiKEjzAuJX0S9a3gvMWEPqixK53d/5D9QkRubxGogPo+UXg9yOEHbKkpKn7veLD+fNPuoWAIzid7aRSx8P01ZHervzTMshJE9yUSdMJSJysgbQborBKD0yV98PAIRbK8OgBKfXSic/ecGX1scxn2HIp8mzKPrpOBMd7YD8z95gROtSveAbKA4yhv3AdtCFZCGFPHsmt+6+rf1dJ+XL9ysfafLtbm507Ms01eAcNtNKuIaT7rtGcDoi77/EAc6ENRAqajVXZnjdA78XYvsiuqsKfXRDkMsFiH/grSxe4AI/goaOZsz6ahS8PDV36cePSsW/9E5ZWWfI5FmWUuDYuBL+NjVKW9EHdP9ERFKdh5U0/i7R4DXYl2vtsUqP1j74YYx9Fbj9OsqSqTA4jIPAMc8G2O8pJx0gJ+vLXr7YxEzW9mp45JA/1SGGlW3L4YW/ENyh2Aoh6PdPJ0XacLWsevIq8kuJYgDrgFpz52dO3vlMHz93U+pdHtelEgaqLmXOVEdvbKimJLmPa0Fe+I2cDrH5THt3APbO0=,iv:fQXqwrVKP2rqdYdRkVWlKxaB0w/Lc+Uf5i42fsdXDW8=,tag:UgTlsBylDI8ZjaM/smF2hA==,type:str]
passphrase:
secret: ENC[AES256_GCM,data:OWA7EULEzMMs,iv:k2WX+BP0qxIPVH5TgT2r2Mg7PRpfTcm89rOdRi2srzc=,tag:AbSGUKMmXcm0RW8+Az3taw==,type:str]
user:
text: daggerci
sops:
kms: []
gcp_kms: []
azure_kv: []
hc_vault: []
age:
- recipient: age1gxwmtwahzwdmrskhf90ppwlnze30lgpm056kuesrxzeuyclrwvpsupwtpk
enc: |
-----BEGIN AGE ENCRYPTED FILE-----
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBDWjNjVWhSUnNuS2xaWFR2
Tm12UFg3elE0MUhILzJ0TkppQzR1VzZiUUMwClBwbncrR2VYVmxlZ09OUk1qV2tE
dURUZG1QVGZLdWM5WFlIQkF2UFB1YkUKLS0tIGFkN1VCajdkcHJRUk1YODBaWDFF
cm02K1NEenRnL25zc3RtaXd6SlA0UXcKFq38uYqZWvSlTOaisnhnQ+Mhbcv+ZifE
Mdxhq5w+Cdj+XhwbZ8UnnRInckD3UKovxAHV3kTSdXf54/QKn5TLVw==
-----END AGE ENCRYPTED FILE-----
lastmodified: "2021-06-03T11:42:23Z"
mac: ENC[AES256_GCM,data:FoRbtx3IwLsyVWlhG4+0P5gmYXygURRiHCCnWX9rfYmCtPyCV1GE0nGQg8nSuAVr1AMhEZ8dx0/WU6o/YHpEfZtTywB83RlL7WFFC4Tn9SVsgzpzA9XyB8TIYgGgzj859xn35iDV27jWnAmQEDL+cWKiOgghx8P4hhRoOurH/Qg=,iv:Cm0gX0UGzrWUnuMv2hKaVY9X92VLTUkv1+nDypYPd4o=,tag:bU8fTYrZMDQWFpscckYoPg==,type:str]
pgp: []
encrypted_suffix: secret
version: 3.7.1

View File

@ -1,20 +0,0 @@
package docker
import (
"dagger.io/docker"
"dagger.io/dagger"
)
// Run with --input-file key=$HOME/.ssh/<your private server key>
key: dagger.#Artifact
passphrase: dagger.#Secret
user: dagger.#Secret
TestRun: run: docker.#Run & {
host: "143.198.64.230"
ref: "nginx:alpine"
"user": user
passphrase: "foobarbaz"
name: "daggerci-test-simple-\(random)"
"key": key
}