Compare commits

...

29 Commits
master ... main

Author SHA1 Message Date
Sambo Chea 61958699cd Task: Add docker from cubetiq docker image and replaced docker container 2021-07-14 18:06:46 +07:00
Sambo Chea 45ff40b618 Updated the path 2021-07-14 18:00:41 +07:00
Sambo Chea 2f566a1e13 Updated hhello 2021-07-14 17:59:32 +07:00
Sambo Chea 674571c0f0 Updated the main 2021-07-14 17:58:14 +07:00
Sambo Chea dae0659e8e Updated the hello 2021-07-14 17:56:56 +07:00
Sambo Chea 5586d63f9b Updated the test 2021-07-14 17:55:02 +07:00
Sambo Chea be58ae76d0 Updated 2021-07-14 17:52:46 +07:00
Sambo Chea cd0490fb70 Updated for test 2021-07-14 17:50:20 +07:00
Sambo Chea a30d400d2f Updated 2021-07-14 17:44:21 +07:00
Sambo Chea 3b83d1da31 Fixed rm and it docker 2021-07-14 17:40:04 +07:00
Sambo Chea b24bcdae82 Add mount vol 2021-07-14 17:39:08 +07:00
Sambo Chea dc9d8aa304 Updated 2021-07-14 17:35:20 +07:00
Sambo Chea 1c3f7a6a60 Updated shell and entrypoint 2021-07-14 17:32:39 +07:00
Sambo Chea ad26e9d001 Updated 2021-07-14 17:28:10 +07:00
Sambo Chea 49f8a851cc Updated docker exec 2021-07-14 17:26:38 +07:00
Sambo Chea 836901cd96 Updated 2021-07-14 17:23:00 +07:00
Sambo Chea f355e30a25 Updated for echo and workdir 2021-07-14 17:21:39 +07:00
Sambo Chea 0c1a69af4f Updated workdir 2021-07-14 17:17:57 +07:00
Sambo Chea 89b39e7ceb Updated ls 2021-07-14 17:16:04 +07:00
Sambo Chea 34a09d857a Updated workdir 2021-07-14 17:15:43 +07:00
Sambo Chea 4aa0c663aa Updated current pwd 2021-07-14 17:12:11 +07:00
Sambo Chea a90ff6a108 Updated to cubetiq docker 2021-07-14 17:10:48 +07:00
Sambo Chea 116e65d151 Updated ls outside 2021-07-14 17:10:14 +07:00
Sambo Chea 638777f7cd ls content 2021-07-14 17:05:40 +07:00
Sambo Chea ca57f79e17
Update main.yml 2021-07-14 17:02:29 +07:00
Sambo Chea fc5f3f562f Add action checkout 2021-07-14 17:02:20 +07:00
Sambo Chea dc17b739ed Just add ls and pwd 2021-07-14 16:56:07 +07:00
Sambo Chea 43ff54bfef Add main branch and updated github actions 2021-07-14 15:24:51 +07:00
Sambo Chea edfb7edf36
Merge pull request #1 from CUBETIQ/master
Add GitHub Workflows and Update
2021-07-14 15:22:31 +07:00
5 changed files with 22 additions and 14 deletions

View File

@ -2,14 +2,18 @@ name: CI
on:
push:
branches: [ master ]
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Starter Docker Test
uses: cubetiq/starter-docker-actions@v1
-
name: Checkout
uses: actions/checkout@v2
-
name: Starter Docker Action Test
uses: cubetiq/starter-docker-actions@main
with:
run: docker version
run: docker version; pwd; ls; docker ps

2
.gitignore vendored
View File

@ -1 +1 @@
.DS_Store
.dccache

View File

@ -1,6 +1,6 @@
FROM docker:latest
FROM cubetiq/calpine-docker:latest
RUN apk add bash
RUN apk update
COPY ./entrypoint.sh /entrypoint.sh

View File

@ -9,7 +9,7 @@
```yaml
- name: Starter Docker
uses: CUBETIQ/starter-docker-actions@v1
uses: CUBETIQ/starter-docker-actions@main
```
# Example Action
@ -19,7 +19,7 @@ name: CI
on:
push:
branches: [ master ]
branches: [ main ]
jobs:
build:
@ -27,7 +27,7 @@ jobs:
steps:
- name: Starter Docker Test
uses: cubetiq/starter-docker-actions@v1
uses: cubetiq/starter-docker-actions@main
with:
shell: sh
run: docker version

View File

@ -1,4 +1,8 @@
#!/bin/bash
#!/bin/sh
#### Current working directory is: /github/workspace ####
WORKDIR=$(pwd)
echo "Working directory => $WORKDIR"
if [ ! -z $INPUT_USERNAME ];
then echo $INPUT_PASSWORD | docker login $INPUT_REGISTRY -u $INPUT_USERNAME --password-stdin
@ -11,15 +15,15 @@ then INPUT_OPTIONS="$INPUT_OPTIONS --network $INPUT_DOCKER_NETWORK"
fi
if [ -z $INPUT_SHELL ];
then INPUT_SHELL=sh
then INPUT_SHELL=/bin/sh
fi
if [ -z $INPUT_IMAGE ];
then INPUT_IMAGE=docker
then INPUT_IMAGE=cubetiq/calpine-docker
fi
if [ -z $semicolon_delimited_script ];
then semicolon_delimited_script="echo $(whoami)"
fi
exec docker run -v "/var/run/docker.sock":"/var/run/docker.sock" $INPUT_OPTIONS --entrypoint=$INPUT_SHELL $INPUT_IMAGE -c "`cat semicolon_delimited_script`"
exec docker run --workdir $WORKDIR -v "$WORKDIR":"$WORKDIR" -v "/var/run/docker.sock":"/var/run/docker.sock" $INPUT_OPTIONS --entrypoint=$INPUT_SHELL $INPUT_IMAGE -c "`cat semicolon_delimited_script`"