generated from container/tmpl
winloong
2 years ago
1 changed files with 22 additions and 0 deletions
@ -0,0 +1,22 @@ |
|||||
|
#!/bin/sh |
||||
|
|
||||
|
auth_zhiwucloud="bGl4aWFvbWluQGFueGluam95LmNvbTp1Njk4RUsxcGsx" |
||||
|
|
||||
|
auth_anxinyun_ali="aGk1MDA0MDIwMUBhbGl5dW4uY29tOlY5cnRDbnQkZg==" |
||||
|
|
||||
|
cp /root/.docker/config.json.temp /root/.docker/config.json |
||||
|
|
||||
|
case $1 in |
||||
|
"zhiwucloud") |
||||
|
echo "user is $1, use $1's auth " |
||||
|
sed -i "s@==auth==@${auth_zhiwucloud}@g" /root/.docker/config.json |
||||
|
;; |
||||
|
"anxinyun") |
||||
|
echo "user is $1, use $1's auth " |
||||
|
sed -i "s@==auth==@${auth_anxinyun_ali}@g" /root/.docker/config.json |
||||
|
;; |
||||
|
*) |
||||
|
echo "user is $1, not found $1's auth " |
||||
|
;; |
||||
|
esac |
||||
|
|
Loading…
Reference in new issue